selinux: fix overflow and 0 length allocations
authorWilliam Roberts <william.c.roberts@intel.com>
Tue, 30 Aug 2016 16:28:11 +0000 (09:28 -0700)
committerPaul Moore <paul@paul-moore.com>
Tue, 30 Aug 2016 19:45:50 +0000 (15:45 -0400)
commit7c686af071ade663d0995aa30b262495a6c68c88
treedc9d17f0b475edc7c371475a33fa8683eb3802cd
parent3bc7bcf69bbe763359454b2c40efcba22730e181
selinux: fix overflow and 0 length allocations

Throughout the SELinux LSM, values taken from sepolicy are
used in places where length == 0 or length == <saturated>
matter, find and fix these.

Signed-off-by: William Roberts <william.c.roberts@intel.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
security/selinux/ss/conditional.c
security/selinux/ss/policydb.c