Received: by 2002:a17:90b:8d0:0:0:0:0 with SMTP id ds16csp5059069pjb; Mon, 27 Jul 2020 11:51:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz85Wsqkra7Jbe1rg8HlCxb6AsUMpJaNZMpLD8eOvMXEme2llpAtIyVznKyalaDDDPDHq77 X-Received: by 2002:a05:6402:363:: with SMTP id s3mr22059710edw.238.1595875904224; Mon, 27 Jul 2020 11:51:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595875904; cv=none; d=google.com; s=arc-20160816; b=vosIundDNGKFEUR/Qu3CeJP0VQix6EwV7kvuSwEL28SJrE8v7PYKENGKbW3X0h4s30 Wr1p83fL0ZJ7kMUgIpZwH9MNiTJKpTSMNBHS+DKTS2kyYppZlqumIIRvRcuYYYMsIgpP 2Hyq+CjF86aASfGEP+RgcBVEv5vvMy/QTd7h3Dkcxb3tkSu9oB8Edif/RtRXoZ+/EF3/ 67ykmoKXPWKRs8MgJM8wdFYPwdgZkQytqy+6W6P1fY8gZeQIRIjjiQ3NQ2K67TDdgUeM KGIwr792BuLUEqQbyMCeLJl3DvEHpT5zxkou9kyjPrdGRGsTOK6I6YzuxKQDwGnX+7Aj 18CA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id :dkim-signature; bh=0fZZcz7vav4bDhifgH/nm9Ttga9GiyHoKc90CtFk/0I=; b=lmxKEvfb82fqhFp4pHw9wtWRCWCPbq9e5CdUjj/lBdvL+laeYAPWkfoknt9IE9z305 zttcJyPTpSkFrDF7HGlSHTccrM1a16mhRk7xF40QaANveifRGu0NzT2KJWk9DaYGxVxe 9m0pzOFKdB53aHibLIsO3PcYh3gfMLzd7Jx2IKDDsqfvDeX19LiFI/Xbk/G5j1f+nEoK oTzm8AJMIxV9Kf/BoE++YFzw5gT4Lf/ufXZK/BAcoI60d/BDoQXoAZVnYNFbplrqNHkv 7ALyil7nfUIov7iNtQ3R6AMPxD5uLMLNtyzUpbzBRNN8JVt0dNkrd16fIZ1rya6RAhRP WU5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=AUvFcPrK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d11si4709098edr.595.2020.07.27.11.51.22; Mon, 27 Jul 2020 11:51:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=AUvFcPrK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732060AbgG0Q3t (ORCPT + 99 others); Mon, 27 Jul 2020 12:29:49 -0400 Received: from mail.kernel.org ([198.145.29.99]:58244 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732011AbgG0Q3r (ORCPT ); Mon, 27 Jul 2020 12:29:47 -0400 Received: from localhost.localdomain (pool-96-246-152-186.nycmny.fios.verizon.net [96.246.152.186]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E521B2074F; Mon, 27 Jul 2020 16:29:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1595867387; bh=nDlItEL5wpDX+RL6B9cqSzJxrB0KNzx+009Wx5gZswo=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=AUvFcPrKk6nVVZv/g3ZXTJTRo3msOEi2ugV5VFd6nCUhGxiVWQy+/OsvXmWbtA4N8 T4qzgDX9jr+r5rVsV27ANM7PbW9GF/6uZqcn4cFuiGrZOgBna91PS6uAVoSSCsvdk8 9qnTOezy0zA1q9PvNJqxKiqVn93pmZocMgzMoLoE= Message-ID: <1595867384.4841.136.camel@kernel.org> Subject: Re: [PATCH v3 10/19] fs/kernel_read_file: Add file_size output argument From: Mimi Zohar To: Kees Cook , Greg Kroah-Hartman Cc: Scott Branden , Luis Chamberlain , Jessica Yu , SeongJae Park , KP Singh , linux-efi@vger.kernel.org, linux-security-module@vger.kernel.org, linux-integrity@vger.kernel.org, selinux@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Date: Mon, 27 Jul 2020 12:29:44 -0400 In-Reply-To: <20200724213640.389191-11-keescook@chromium.org> References: <20200724213640.389191-1-keescook@chromium.org> <20200724213640.389191-11-keescook@chromium.org> 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 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 2020-07-24 at 14:36 -0700, Kees Cook wrote: > In preparation for adding partial read support, add an optional output > argument to kernel_read_file*() that reports the file size so callers > can reason more easily about their reading progress. > > Acked-by: Scott Branden > Signed-off-by: Kees Cook Reviewed-by: Mimi Zohar