Skip to content
Commit 95ebabde authored by Eric W. Biederman's avatar Eric W. Biederman
Browse files

capabilities: Don't allow writing ambiguous v3 file capabilities

The v3 file capabilities have a uid field that records the filesystem
uid of the root user of the user namespace the file capabilities are
valid in.

When someone is silly enough to have the same underlying uid as the
root uid of multiple nested containers a v3 filesystem capability can
be ambiguous.

In the spirit of don't do that then, forbid writing a v3 filesystem
capability if it is ambiguous.

Fixes: 8db6c34f

 ("Introduce v3 namespaced file capabilities")
Reviewed-by: default avatarAndrew G. Morgan <morgan@kernel.org>
Reviewed-by: default avatarSerge Hallyn <serge@hallyn.com>
Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
parent 5c8fe583
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