Date: Thu, 7 Mar 2013 00:07:46 +0000 From: Nicholas Wilson <nicholas@nicholaswilson.me.uk> To: "freebsd-hackers@freebsd.org" <freebsd-hackers@freebsd.org> Subject: mkdir & open not setting sticky bit Message-ID: <CAN%2BZGEntGAcftNt0G4oC5ya7m%2B7kwF-hDh_otpmb2jFOVpbZSA@mail.gmail.com> In-Reply-To: <CAN%2BZGEkH5UG-sqKrtaaANFgBwWy3uPOptY0VzEqiWV=Zp%2BXrUQ@mail.gmail.com> References: <CAN%2BZGEkH5UG-sqKrtaaANFgBwWy3uPOptY0VzEqiWV=Zp%2BXrUQ@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Hello, I'm guessing it's well known that BUGS in sticky(8) explains that BSD mkdir doesn't set the sticky bit. I'd like to fix that, but the fact that it's still there from historical BSD code suggests it's going to break something to change it (or surely it would have been done already!). I can't find a PR or any discussion over it though. It would be good to fix it, because of all the seven unixes our company supports, BSD's the only one with this quirk. Imagine if someone shipped a product with a security bug because directories weren't being created with the correct permissions? I might easily have done. If I wrote a patch for it, would I be wasting my time? The only difficulty I can imagine is changing semantics for existing applications, which seems extremely unlikely to cause breakage for this call. umask is ignored so doesn't complicate things; and POSIX & XSI explicitly allow both the current behaviour, and that implemented on every other Unix. Best, Nicholas
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAN%2BZGEntGAcftNt0G4oC5ya7m%2B7kwF-hDh_otpmb2jFOVpbZSA>