From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/6196 Path: news.gmane.org!not-for-mail From: u-wsnj@aetey.se Newsgroups: gmane.linux.lib.musl.general Subject: Re: faccessat and AT_SYM_NOFOLLOW Date: Thu, 25 Sep 2014 18:46:14 +0200 Message-ID: <20140925164614.GO20593@example.net> References: <20140925160110.GA25937@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1411663611 10437 80.91.229.3 (25 Sep 2014 16:46:51 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 25 Sep 2014 16:46:51 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-6209-gllmg-musl=m.gmane.org@lists.openwall.com Thu Sep 25 18:46:44 2014 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1XXCBm-0000Vb-IE for gllmg-musl@plane.gmane.org; Thu, 25 Sep 2014 18:46:42 +0200 Original-Received: (qmail 22379 invoked by uid 550); 25 Sep 2014 16:46:41 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 22366 invoked from network); 25 Sep 2014 16:46:41 -0000 X-T2-Spam-Status: No, hits=0.8 required=5.0 tests=BAYES_50 Received-SPF: none receiver=mailfe03.swip.net; client-ip=62.210.74.143; envelope-from=u-wsnj@aetey.se Content-Disposition: inline In-Reply-To: <20140925160110.GA25937@brightrain.aerifal.cx> User-Agent: Mutt/1.5.23 (2014-03-12) Xref: news.gmane.org gmane.linux.lib.musl.general:6196 Archived-At: On Thu, Sep 25, 2014 at 12:01:10PM -0400, Rich Felker wrote: > to get the file ownership and mode and performs its own access > permissions check in userspace. This is imprecise and does not > respect ACLs or any other advanced permission models provided by Of course, that's plainly wrong. > So my conclusion? There are some moderate-level documentation errors. > glibc implements the flag, but not correctly. The changes I would > recommend to the documentation: > > 1. Document that AT_SYM_NOFOLLOW is not standard for this function, > and is a glibc extension. (uclibc is just a copy of glibc code) > > 2. Document that AT_SYM_NOFOLLOW and AT_EACCESS are emulated and > unreliable on glibc. > > 3. Document that the man page is covering the POSIX/glibc function > details, and the kernel syscall does not support flags at all. > (This might aid in getting the kernel folks to add a new faccessat4 > syscall that would do flags at the kernel level.) > > Do these sound reasonable? Yes (but I would look for a stronger wording than "unreliable" :) > Issue 2: Should musl support or ignore the AT_SYM_NOFOLLOW with > faccessat? [your analysis looks for my eyes correct] I would not bother implementing something which does not make sense (worse, would mislead the programmers, iow inflicting damage instead of doing any good). Regards, Rune