From mboxrd@z Thu Jan 1 00:00:00 1970 From: Miklos Szeredi Subject: Re: [PATCH 0/8] Security: Provide unioned file support Date: Fri, 19 Jun 2015 10:36:03 +0200 Message-ID: References: <20150618133215.12722.70352.stgit@warthog.procyon.org.uk> <20150619072015.GH17109@ZenIV.linux.org.uk> <20150619075903.GI17109@ZenIV.linux.org.uk> <20150619081128.GA24181@tucsk> <20150619082928.GJ17109@ZenIV.linux.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Cc: David Howells , sds@tycho.nsa.gov, Linux-Fsdevel , linux-security-module@vger.kernel.org, "linux-unionfs@vger.kernel.org" , Kernel Mailing List To: Al Viro Return-path: Received: from mail-qg0-f48.google.com ([209.85.192.48]:35246 "EHLO mail-qg0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754429AbbFSIgE (ORCPT ); Fri, 19 Jun 2015 04:36:04 -0400 Received: by qgeu36 with SMTP id u36so34165417qge.2 for ; Fri, 19 Jun 2015 01:36:03 -0700 (PDT) In-Reply-To: <20150619082928.GJ17109@ZenIV.linux.org.uk> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, Jun 19, 2015 at 10:29 AM, Al Viro wrote: > Directory, probably? > >> - dentry = lookup_one_len(name, parent->dentry, namelen); >> + dentry = lookup_one_len(name, parent, namelen); > > ... it would better be one. My point is: without a bloody accessor, there's no way to warn if the use is illegal (i.e. nondirectory). Maybe we won't need file->f_dentry, but we do need a way to WARN about abuse (which there IS probably a significant number already and nothing preventing more). Thanks, Miklos