3 ms·
As a complete aside, I'm currently working on a patchset to add O_BENEATH (and some other path resolution restriction flags) to Linux. https://lore.kernel.org/
by cyphar 8y ago
As a complete aside, I'm currently working on a patchset to add O_BENEATH (and some other path resolution restriction flags) to Linux.
https://lore.kernel.org/patchwork/cover/1011459/ https://lore.kernel.org/patchwork/cover/1011459/
- loeg 8y agoThanks for working to incorporate it in Linux. FreeBSD has moved to be compatible with the proposed Linux O_BENEATH as well[1]. We're hoping this helps write portable, capability-restricted code between FreeBSD and Linux. [1]: https://svnweb.freebsd.org/base?view=revision&revision=339748 https://svnweb.freebsd.org/base?view=revision&revision=33974... (We already had very similar functionality for Capsicum-restricted directory fds to piggy-back off of.)
- cyphar 8y agoYes, though FreeBSD's O_BENEATH would probably have to be done using (O_BENEATH|O_NOMAGICLINKS|O_XDEV). Linus, Andy and Al were very insistent that various parts should be split into separate flags.