platform_external_selinux/libsepol
James Carter 1fc2f2f5ca libsepol/cil: Check for improper category range
Nicolas Iooss found while fuzzing secilc with AFL that the following
policy will cause a segfault.

(category c0)
(category c1)
(categoryorder (c0 c1))
(sensitivity s0)
(sensitivitycategory s0 (range c1 c0))

The category range "(range c1 c0)" is invalid because c1 comes after c0
in order.

The invalid range is evaluated as containing no categories. There is a
check for the resulting empty list and the category datum expression is
set to NULL. The segfault occurs because the datum expression is assumed
to be non-NULL after evaluation.

Add a check for an invalid range when evaluating category ranges.

Signed-off-by: James Carter <jwcart2@tycho.nsa.gov>
2016-10-19 10:07:22 -04:00
..
cil libsepol/cil: Check for improper category range 2016-10-19 10:07:22 -04:00
include libsepol/cil: create user and role caches when building binary policy 2016-10-03 14:59:23 -04:00
man Laurent Bigonville patch to fix various minor manpage issues and correct section numbering. 2013-10-24 13:58:37 -04:00
src libsepol: build on mac 2016-10-18 13:49:36 -04:00
tests libsepol/tests: fix mispelling of optimization option 2016-09-26 11:08:53 -04:00
utils libsepol: Android/MacOS X build support 2012-06-28 11:21:15 -04:00
.gitignore libsepol: build cil into libsepol 2014-08-26 08:03:31 -04:00
ChangeLog Updated libselinux and libsepol ChangeLogs 2016-10-18 14:03:21 -04:00
COPYING initial import from svn trunk revision 2950 2008-08-19 15:30:36 -04:00
Makefile libsepol: build cil into libsepol 2014-08-26 08:03:31 -04:00
VERSION Update VERSION and ChangeLog files for 2.6 final release. 2016-10-14 11:31:26 -04:00