[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFx8dKi7bvuqwPg_wjhTWtyty=u8fqxqsJuTHhVLjpJH6Q@mail.gmail.com>
Date: Tue, 19 Apr 2016 17:18:26 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: "H. Peter Anvin" <hpa@...or.com>
Cc: "Eric W. Biederman" <ebiederm@...ssion.com>,
Andy Lutomirski <luto@...capital.net>, security@...ian.org,
"security@...nel.org" <security@...nel.org>,
Al Viro <viro@...iv.linux.org.uk>,
"security@...ntu.com >> security" <security@...ntu.com>,
Peter Hurley <peter@...leysoftware.com>,
Serge Hallyn <serge.hallyn@...ntu.com>,
Willy Tarreau <w@....eu>,
Aurelien Jarno <aurelien@...el32.net>,
One Thousand Gnomes <gnomes@...rguk.ukuu.org.uk>,
Jann Horn <jann@...jh.net>, Greg KH <greg@...ah.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Jiri Slaby <jslaby@...e.com>, Florian Weimer <fw@...eb.enyo.de>
Subject: Re: Does anyone care about a race free ptsname?
On Tue, Apr 19, 2016 at 4:39 PM, H. Peter Anvin <hpa@...or.com> wrote:
>
> What do you think of the idea of TIOCPTSOPEN (or whatever) to get a file
> descriptor for the slave device given the master device? Then we can
> use realpath() or a readlink on /proc/self/fd/# to get the pathname if
> needed.
That sounds reasonable to me.
> (Incidentally, we added getcwd() as a system call. Should we add
> [f]realpath() as a system call too?)
Probably a good idea. It's kind of silly to have to do a sprintf
followed by a readlink().
Linus
Powered by blists - more mailing lists