aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/net/lib/py/utils.py
diff options
context:
space:
mode:
authorMikhail Ivanov <[email protected]>2024-11-12 14:52:03 +0000
committerPaul Moore <[email protected]>2024-12-11 19:57:47 +0000
commit034294fbfdf0ded4f931f9503d2ca5bbf8b9aebd (patch)
tree9a443dec1607ebe064a83bd3335b8efe13a34995 /tools/testing/selftests/net/lib/py/utils.py
parentselinux: use native iterator types (diff)
downloadkernel-034294fbfdf0ded4f931f9503d2ca5bbf8b9aebd.tar.gz
kernel-034294fbfdf0ded4f931f9503d2ca5bbf8b9aebd.zip
selinux: Fix SCTP error inconsistency in selinux_socket_bind()
Check sk->sk_protocol instead of security class to recognize SCTP socket. SCTP socket is initialized with SECCLASS_SOCKET class if policy does not support EXTSOCKCLASS capability. In this case bind(2) hook wrongfully return EAFNOSUPPORT instead of EINVAL. The inconsistency was detected with help of Landlock tests: https://lore.kernel.org/all/[email protected]/ Fixes: 0f8db8cc73df ("selinux: add AF_UNSPEC and INADDR_ANY checks to selinux_socket_bind()") Signed-off-by: Mikhail Ivanov <[email protected]> Signed-off-by: Paul Moore <[email protected]>
Diffstat (limited to 'tools/testing/selftests/net/lib/py/utils.py')
0 files changed, 0 insertions, 0 deletions