selinux: Assign proper class to PF_UNIX/SOCK_RAW sockets
For PF_UNIX, SOCK_RAW is synonymous with SOCK_DGRAM (cf. net/unix/af_unix.c). This is a tad obscure, but libpcap uses it. Signed-off-by: Luis Ressel <aranea@aixah.de> Acked-by: Stephen Smalley <sds@tycho.nsa.gov> Signed-off-by: Paul Moore <paul@paul-moore.com>
This commit is contained in:
parent
31368ce83c
commit
2a764b529a
|
@ -1303,6 +1303,7 @@ static inline u16 socket_type_to_security_class(int family, int type, int protoc
|
|||
case SOCK_SEQPACKET:
|
||||
return SECCLASS_UNIX_STREAM_SOCKET;
|
||||
case SOCK_DGRAM:
|
||||
case SOCK_RAW:
|
||||
return SECCLASS_UNIX_DGRAM_SOCKET;
|
||||
}
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue
Block a user