diff options
| author | Alexey Kodanev <[email protected]> | 2018-05-11 17:15:11 +0000 |
|---|---|---|
| committer | Paul Moore <[email protected]> | 2018-05-14 19:17:02 +0000 |
| commit | 0f8db8cc73df60b3de9a5eebd8f117b56eff5b03 (patch) | |
| tree | c890791d42e34d4dcb9bad3307143246a13adb81 /drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | |
| parent | selinux: wrap AVC state (diff) | |
| download | kernel-0f8db8cc73df60b3de9a5eebd8f117b56eff5b03.tar.gz kernel-0f8db8cc73df60b3de9a5eebd8f117b56eff5b03.zip | |
selinux: add AF_UNSPEC and INADDR_ANY checks to selinux_socket_bind()
Commit d452930fd3b9 ("selinux: Add SCTP support") breaks compatibility
with the old programs that can pass sockaddr_in structure with AF_UNSPEC
and INADDR_ANY to bind(). As a result, bind() returns EAFNOSUPPORT error.
This was found with LTP/asapi_01 test.
Similar to commit 29c486df6a20 ("net: ipv4: relax AF_INET check in
bind()"), which relaxed AF_INET check for compatibility, add AF_UNSPEC
case to AF_INET and make sure that the address is INADDR_ANY.
Fixes: d452930fd3b9 ("selinux: Add SCTP support")
Signed-off-by: Alexey Kodanev <[email protected]>
Signed-off-by: Paul Moore <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_object.c')
0 files changed, 0 insertions, 0 deletions
