diff options
| author | Ondrej Mosnacek <[email protected]> | 2024-01-26 18:45:31 +0000 |
|---|---|---|
| committer | Paul Moore <[email protected]> | 2024-01-30 22:01:54 +0000 |
| commit | 5a287d3d2b9de2b3e747132c615599907ba5c3c1 (patch) | |
| tree | 9678de7e208789e322d4799e85dbd1a5c64d0d2b /scripts/bpf_doc.py | |
| parent | lsm: fix the logic in security_inode_getsecctx() (diff) | |
| download | kernel-5a287d3d2b9de2b3e747132c615599907ba5c3c1.tar.gz kernel-5a287d3d2b9de2b3e747132c615599907ba5c3c1.zip | |
lsm: fix default return value of the socket_getpeersec_*() hooks
For these hooks the true "neutral" value is -EOPNOTSUPP, which is
currently what is returned when no LSM provides this hook and what LSMs
return when there is no security context set on the socket. Correct the
value in <linux/lsm_hooks.h> and adjust the dispatch functions in
security/security.c to avoid issues when the BPF LSM is enabled.
Cc: [email protected]
Fixes: 98e828a0650f ("security: Refactor declaration of LSM hooks")
Signed-off-by: Ondrej Mosnacek <[email protected]>
[PM: subject line tweak]
Signed-off-by: Paul Moore <[email protected]>
Diffstat (limited to 'scripts/bpf_doc.py')
0 files changed, 0 insertions, 0 deletions
