lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 17 Nov 2022 16:42:30 -0500
From:   Jeff Layton <jlayton@...nel.org>
To:     Richard Weinberger <richard@....at>
Cc:     linux-nfs <linux-nfs@...r.kernel.org>,
        linux-kernel <linux-kernel@...r.kernel.org>,
        linux-fsdevel <linux-fsdevel@...r.kernel.org>,
        chuck lever <chuck.lever@...cle.com>, anna@...nel.org,
        trond myklebust <trond.myklebust@...merspace.com>,
        Al Viro <viro@...iv.linux.org.uk>, raven@...maw.net,
        chris chilvers <chris.chilvers@...sbroker.com>,
        david young <david.young@...sbroker.com>,
        luis turcitu <luis.turcitu@...sbroker.com>,
        david <david@...ma-star.at>
Subject: Re: [PATCH 2/3] fs: namei: Allow follow_down() to uncover auto
 mounts

On Thu, 2022-11-17 at 22:12 +0100, Richard Weinberger wrote:
> ----- Ursprüngliche Mail -----
> > Von: "Jeff Layton" <jlayton@...nel.org>
> > What happens when CROSSMOUNT isn't enabled and someone tries to stroll
> > into an automount point? I'm guessing the automount happens but the
> > export is denied? 
> 
> Exactly.
> 
> On the other hand, why should knfsd not trigger automounts?
> Almost any userspace interaction would also do so.
> 

I have no issue with knfsd activity triggering an automount, but I think
it'd be best if we don't do that when knfsd can't do anything with the
resulting filesystem. Automounts can be expensive.

> > It seems like LOOKUP_AUTOMOUNT ought to be conditional
> > on the parent export having CROSSMOUNT set.
> > 
> > There's also another caller of follow_down too, the UNIX98 pty code.
> > This may be harmless for it, but it'd be best not to perturb that if we
> > can help it.
> > 
> > Maybe follow_down can grow a lookupflags argument?
> 
> So, in nfsd_cross_mnt() the follow_down() helper should use LOOKUP_AUTOMOUNT only
> if exp->ex_flags & NFSEXP_CROSSMOUNT is true?
> Sounds sane, thanks for the pointer.
> 

Yeah, I think so. I do wonder if we ought to make any provision for
"nohide" exports, but since you have to enumerate those explicitly, it
shouldn't be a huge problem for someone to just ensure that they're
mounted beforehand.

-- 
Jeff Layton <jlayton@...nel.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ