Re: [PATCH 01/14] VFS: Add additional RESOLVE_* flags [ver #18]

From
Stefan Metzmacher <metze@samba.org>
Date
2020-03-09 20:56:37
Also in
linux-fsdevel, linux-security-module, lkml
Reply to
David Howells, 2020-03-09
Hi David,
Add additional RESOLVE_* flags to correspond to AT_* flags that aren't
currently implemented:

	RESOLVE_NO_TRAILING_SYMLINKS    for AT_SYMLINK_NOFOLLOW
	RESOLVE_NO_TRAILING_AUTOMOUNTS  for AT_NO_AUTOMOUNT
	RESOLVE_EMPTY_PATH              for AT_EMPTY_PATH
Thanks for changing the names!
This is necessary for fsinfo() to use RESOLVE_* flags instead of AT_* flags
if the latter are to be considered deprecated for new system calls.

Also make openat2() handle RESOLVE_NO_TRAILING_SYMLINKS.

Automounting is currently forced by doing an open(), so adding support to
openat2() for RESOLVE_NO_TRAILING_AUTOMOUNTS is not trivial.
lookup_flags &= ~LOOKUP_AUTOMOUNT won't work?

At least it should cause EINVAL (or something similar) instead of being
silently ignored. The same applies to RESOLVE_EMPTY_PATH, it should be
handled with some logic or also cause EINVAL.

vfs_statx()/vfs_stat_set_lookup_flags() seems to have a similar logic
using the AT_* flags.

metze

Attachments

Thread (29 messages) 29 messages, 6 authors, last reply 2020-03-10
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help