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  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:	Tue, 5 Apr 2016 04:03:33 +0100
From:	Al Viro <>
To:	"Eric W. Biederman" <>
Cc:	Linus Torvalds <>,
	"H. Peter Anvin" <>,
	Peter Hurley <>,
	Greg KH <>, Jiri Slaby <>,
	Aurelien Jarno <>,
	Andy Lutomirski <>,
	Florian Weimer <>,
	Serge Hallyn <>,
	Jann Horn <>,
	"" <>,,, Willy Tarreau <>,
	Linux Kernel Mailing List <>
Subject: Re: [PATCH 01/13] devpts: Teach /dev/ptmx to find the associated
 devpts via path lookup

On Tue, Apr 05, 2016 at 03:54:25AM +0100, Al Viro wrote:

> That, I take it, is a lookup for .. and buggering off if it fails *or* if
> we had been in caller's root or something that overmount it?  Not that the
> latter had been possible - root is a directory and can be overmounted only
> by another such, and we are called from ->open() of a device node.
> > +	/* Remember the result of this permission check for later */
> > +	ret = inode_permission(path.dentry->d_inode, MAY_EXEC);
> > +	if (path_pts(&path))
> > +		goto fail;
> Egads, man - you've just introduced a special function for looking up
> something named "pts" in a given directory!
> The reason not to use kern_path() would be what, the fact that it doesn't
> allow starting at given location?  So let's make a variant that would - and
> rather than bothering with RCU, just go for something like (completely
> untested)

Ah...  Right, that would demand exec permissions on the starting point.
Still, this is incredibly ugly ;-/  I'll try to come up with something
more tolerable, but this "path_pts" thing is too ugly to live.  Seriously.

Powered by blists - more mailing lists