android_kernel_xiaomi_sm8350/security/selinux
Paul Moore 99d854d231 selinux: Fix a problem in security_netlbl_sid_to_secattr()
Currently when SELinux fails to allocate memory in
security_netlbl_sid_to_secattr() the NetLabel LSM domain field is set to
NULL which triggers the default NetLabel LSM domain mapping which may not
always be the desired mapping.  This patch fixes this by returning an error
when the kernel is unable to allocate memory.  This could result in more
failures on a system with heavy memory pressure but it is the "correct"
thing to do.

Signed-off-by: Paul Moore <paul.moore@hp.com>
Acked-by: James Morris <jmorris@namei.org>
2008-10-10 10:16:30 -04:00
..
include Revert "SELinux: allow fstype unknown to policy to use xattrs if present" 2008-07-15 18:32:49 +10:00
ss selinux: Fix a problem in security_netlbl_sid_to_secattr() 2008-10-10 10:16:30 -04:00
avc.c
exports.c
hooks.c selinux: Better local/forward check in selinux_ip_postroute() 2008-10-10 10:16:30 -04:00
Kconfig
Makefile
netif.c
netlabel.c selinux: Cleanup the NetLabel glue code 2008-10-10 10:16:29 -04:00
netlink.c
netnode.c SELinux: keep the code clean formating and syntax 2008-07-14 15:01:36 +10:00
netport.c SELinux: keep the code clean formating and syntax 2008-07-14 15:01:36 +10:00
nlmsgtab.c
selinuxfs.c SELinux: more user friendly unknown handling printk 2008-07-14 15:02:00 +10:00
xfrm.c