summaryrefslogtreecommitdiff
path: root/security/safesetid/lsm.c
diff options
context:
space:
mode:
authorMichael Ellerman <mpe@ellerman.id.au>2021-05-08 21:12:55 +1000
committerMichael Ellerman <mpe@ellerman.id.au>2021-05-08 21:12:55 +1000
commitf96271cefe6dfd1cb04195b76f4a33e185cd7f92 (patch)
treef290b3e7aa9c12fdc4853ce97c150c4f9abd90a3 /security/safesetid/lsm.c
parent32b48bf8514c28cdc89cd8069eceeb6e6cff0612 (diff)
parentdd860052c99b1e088352bdd4fb7aef46f8d2ef47 (diff)
Merge branch 'master' into next
Merge master back into next, this allows us to resolve some conflicts in arch/powerpc/Kconfig, and also re-sort the symbols under config PPC so that they are in alphabetical order again.
Diffstat (limited to 'security/safesetid/lsm.c')
-rw-r--r--security/safesetid/lsm.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/security/safesetid/lsm.c b/security/safesetid/lsm.c
index 8a176b6adbe5..1079c6d54784 100644
--- a/security/safesetid/lsm.c
+++ b/security/safesetid/lsm.c
@@ -125,7 +125,6 @@ static int safesetid_security_capable(const struct cred *cred,
pr_warn("Operation requires CAP_SETUID, which is not available to UID %u for operations besides approved set*uid transitions\n",
__kuid_val(cred->uid));
return -EPERM;
- break;
case CAP_SETGID:
/*
* If no policy applies to this task, allow the use of CAP_SETGID for
@@ -140,11 +139,9 @@ static int safesetid_security_capable(const struct cred *cred,
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));
return -EPERM;
- break;
default:
/* Error, the only capabilities were checking for is CAP_SETUID/GID */
return 0;
- break;
}
return 0;
}