Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp6816683ybl; Wed, 15 Jan 2020 10:37:50 -0800 (PST) X-Google-Smtp-Source: APXvYqyBClbyfwq/WaH74erNoPq903/Za2WpmMEXTDG0ojX+2dWbbyLkqlslBWtYQHVWjqTRYe/T X-Received: by 2002:aca:f242:: with SMTP id q63mr994894oih.72.1579113470392; Wed, 15 Jan 2020 10:37:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1579113470; cv=none; d=google.com; s=arc-20160816; b=b1RUJ68JMwHXyKYdvSFNF6bZhPWBJyAErjjy79F0u3AahGpnLMlJDyRoSCfkqnB9jl U5xrKpNw7YNfpwjY83adRb6OiWKVOixA/jlk5ueAWrCQPH69L5hj4mSjhdhxH/Umcds8 15fyb491qUnrq8Tvn32Cp0v0tCyUf8giHLAIxW7FeH8o1hYrT4p3aH3V34ojmYxKUfdX 3Mr32Un7YauZG+LZYIec0wjE+olfnYL+qqP/u6UNXMj3sjzTaOv6ynJE0ijnNNZYjP7s Um3DReHzS4X7wZfJ8MOo4ITqvuNmzbYXBL5k1IzzPw0TtOszCOoWkSlmrViz77dQCB+9 NbYQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:content-transfer-encoding :mime-version:references:in-reply-to:date:cc:to:from:subject; bh=JeBHQrsl7JaDoH22kxD+MZyJzpXK2ICCQpVohoGk6Uo=; b=ORFbSUydT016c5WWd6TwIuG4Zgm4PB6Yd0GNRn4dzjcHi23y0rnB+HLMPAnQFaMcp7 hE8R2DejLsmx3ZLlL2TmB+BoVMChQnKmIz4MNvHktvAVD3pwdLW43lhy0Kx4yJ/81WSN GP9/kwJS/f5Xzmu8W95DWW6MLg2u6AfGOV2+LcHXr1CEAAeb4pbrupeLNc5Ugb9UivXH WcPlp+pGAPWBI51YwLk8IBy6EZMAXwe2F3Q5VDE8k4JBv+NnL13+qVEe8TM4opji19Ps bJ9hGsIPkh4REk6MulWL8X4i4jhy/Ss7G7fwk/FatddpJvGBUJXS4ORyRciNOHAFM4s4 PWKw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z15si14229009otj.235.2020.01.15.10.37.38; Wed, 15 Jan 2020 10:37:50 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729305AbgAOSgQ (ORCPT + 99 others); Wed, 15 Jan 2020 13:36:16 -0500 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:41018 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729157AbgAOSgO (ORCPT ); Wed, 15 Jan 2020 13:36:14 -0500 Received: from pps.filterd (m0098414.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 00FIPeTs105831 for ; Wed, 15 Jan 2020 13:36:13 -0500 Received: from e06smtp02.uk.ibm.com (e06smtp02.uk.ibm.com [195.75.94.98]) by mx0b-001b2d01.pphosted.com with ESMTP id 2xhbpsectt-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 15 Jan 2020 13:36:12 -0500 Received: from localhost by e06smtp02.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 15 Jan 2020 18:36:11 -0000 Received: from b06cxnps3075.portsmouth.uk.ibm.com (9.149.109.195) by e06smtp02.uk.ibm.com (192.168.101.132) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Wed, 15 Jan 2020 18:36:09 -0000 Received: from d06av22.portsmouth.uk.ibm.com (d06av22.portsmouth.uk.ibm.com [9.149.105.58]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 00FIa88u47972486 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 15 Jan 2020 18:36:08 GMT Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8E6854C046; Wed, 15 Jan 2020 18:36:08 +0000 (GMT) Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 84B074C04E; Wed, 15 Jan 2020 18:36:07 +0000 (GMT) Received: from localhost.localdomain (unknown [9.85.153.48]) by d06av22.portsmouth.uk.ibm.com (Postfix) with ESMTP; Wed, 15 Jan 2020 18:36:07 +0000 (GMT) Subject: Re: [PATCH v2] ima: add the ability to query the hash of a given file. From: Mimi Zohar To: KP Singh , Florent Revest Cc: linux-integrity@vger.kernel.org, mjg59@google.com, nramas@linux.microsoft.com, linux-kernel@vger.kernel.org, linux-security-module@vger.kernel.org, Florent Revest Date: Wed, 15 Jan 2020 13:36:07 -0500 In-Reply-To: <20200113104830.GA28588@google.com> References: <20200106162524.164650-1-revest@chromium.org> <20200113104830.GA28588@google.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.20.5 (3.20.5-1.fc24) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 x-cbid: 20011518-0008-0000-0000-00000349AB4B X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 20011518-0009-0000-0000-00004A6A0255 Message-Id: <1579113367.5032.19.camel@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138,18.0.572 definitions=2020-01-15_02:2020-01-15,2020-01-15 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=933 impostorscore=0 bulkscore=0 clxscore=1015 lowpriorityscore=0 suspectscore=0 malwarescore=0 priorityscore=1501 adultscore=0 spamscore=0 mlxscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-1910280000 definitions=main-2001150141 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2020-01-13 at 11:48 +0100, KP Singh wrote: > On 06-Jan 17:25, Florent Revest wrote: > > From: Florent Revest > > > > This allows other parts of the kernel (perhaps a stacked LSM allowing > > system monitoring, eg. the proposed KRSI LSM [1]) to retrieve the hash > > of a given file from IMA if it's present in the iint cache. > > > > It's true that the existence of the hash means that it's also in the > > audit logs or in /sys/kernel/security/ima/ascii_runtime_measurements, > > but it can be difficult to pull that information out for every > > subsequent exec. This is especially true if a given host has been up > > for a long time and the file was first measured a long time ago. > > > > This is based on Peter Moody's patch: > > https://sourceforge.net/p/linux-ima/mailman/message/33036180/ > > > > [1] https://lkml.org/lkml/2019/9/10/393 > > > > Signed-off-by: Florent Revest > > Thanks for adding this Florent! > > Reviewed-by: KP Singh Thanks, this patch is now queued in next-integrity-testing. Mimi