From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Biggers Subject: Re: [PATCH v4 07/16] fs-verity: add the hook for file ->open() Date: Tue, 18 Jun 2019 09:35:04 -0700 Message-ID: <20190618163503.GC184520@gmail.com> References: <20190606155205.2872-1-ebiggers@kernel.org> <20190606155205.2872-8-ebiggers@kernel.org> <20190615144207.GH6142@mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <20190615144207.GH6142@mit.edu> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linux-f2fs-devel-bounces@lists.sourceforge.net To: Theodore Ts'o Cc: "Darrick J . Wong" , linux-api@vger.kernel.org, Dave Chinner , linux-f2fs-devel@lists.sourceforge.net, linux-fscrypt@vger.kernel.org, linux-fsdevel@vger.kernel.org, Jaegeuk Kim , linux-integrity@vger.kernel.org, linux-ext4@vger.kernel.org, Linus Torvalds , Christoph Hellwig , Victor Hsieh List-Id: linux-api@vger.kernel.org On Sat, Jun 15, 2019 at 10:42:07AM -0400, Theodore Ts'o wrote: > On Thu, Jun 06, 2019 at 08:51:56AM -0700, Eric Biggers wrote: > > From: Eric Biggers > > > > Add the fsverity_file_open() function, which prepares an fs-verity file > > to be read from. If not already done, it loads the fs-verity descriptor > > from the filesystem and sets up an fsverity_info structure for the inode > > which describes the Merkle tree and contains the file measurement. It > > also denies all attempts to open verity files for writing. > > > > This commit also begins the include/linux/fsverity.h header, which > > declares the interface between fs/verity/ and filesystems. > > > > Signed-off-by: Eric Biggers > > Looks good; you can add: > > Reviewed-off-by: Theodore Ts'o > > - Ted > > > +/* > > + * Validate the given fsverity_descriptor and create a new fsverity_info from > > + * it. The signature (if present) is also checked. > > + */ > > +struct fsverity_info *fsverity_create_info(const struct inode *inode, > > + const void *_desc, size_t desc_size) > > Well, technically it's not checked (yet). It doesn't get checked > until [PATCH 13/16]: support builtin file signatures. If we want to > be really nit-picky, that portion of the comment could be moved to > later in the series. > Yes, I missed this when splitting out the patches. I'll move it to patch 13. - Eric