diff options
author | Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com> | 2023-05-03 09:43:44 +0300 |
---|---|---|
committer | Paul Moore <paul@paul-moore.com> | 2023-06-21 03:26:00 +0300 |
commit | 970ebb8a26a120340dcbb4e6c2fb4ecfbad0d190 (patch) | |
tree | 44421c147315bcb26030bf13efce53d5f03f4731 /security | |
parent | b432b55176443e96b6f3bc39ed140ab00cddd84f (diff) | |
download | linux-970ebb8a26a120340dcbb4e6c2fb4ecfbad0d190.tar.xz |
SafeSetID: fix UID printed instead of GID
pr_warn message clearly says that GID should be printed,
but we have UID there. Let's fix that.
Found accidentally during the work on isolated user namespaces.
Signed-off-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com>
[PM: fix spelling errors in description, subject tweak]
Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'security')
-rw-r--r-- | security/safesetid/lsm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/safesetid/lsm.c b/security/safesetid/lsm.c index e806739f7868..5be5894aa0ea 100644 --- a/security/safesetid/lsm.c +++ b/security/safesetid/lsm.c @@ -131,7 +131,7 @@ static int safesetid_security_capable(const struct cred *cred, * set*gid() (e.g. setting up userns gid mappings). */ pr_warn("Operation requires CAP_SETGID, which is not available to GID %u for operations besides approved set*gid transitions\n", - __kuid_val(cred->uid)); + __kgid_val(cred->gid)); return -EPERM; default: /* Error, the only capabilities were checking for is CAP_SETUID/GID */ |