Skip to content
Commit 38b78a5f authored by Miklos Szeredi's avatar Miklos Szeredi Committed by Al Viro
Browse files

ovl: ignore permissions on underlying lookup



Generally permission checking is not necessary when overlayfs looks up a
dentry on one of the underlying layers, since search permission on base
directory was already checked in ovl_permission().

More specifically using lookup_one_len() causes a problem when the lower
directory lacks search permission for a specific user while the upper
directory does have search permission.  Since lookups are cached, this
causes inconsistency in behavior: success depends on who did the first
lookup.

So instead use lookup_hash() which doesn't do the permission check.

Reported-by: default avatarIgnacy Gawędzki <ignacy.gawedzki@green-communications.fr>
Signed-off-by: default avatarMiklos Szeredi <mszeredi@redhat.com>
parent 3c9fe8cd
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment