platform_external_selinux/libselinux
Richard Haines f7148d5973 Fix more bin file processing core dumps
The reading of bin files has been changed to follow that of loading
policy to catch over-runs. Entries that should be NUL terminated are
also checked. If any error, then process the text file. This should
fix all problems highlighted in [1] with V2 fixing those in [2].
V3 corrects int32_t/uint32_t for *_len entries and V4 fixes [3]
and adds pcre_fullinfo checks to validate regex and study data
sizes. pcre_fullinfo also validates its magic number.

Tested with bin files built using sefcontext_compile PCRE_VERS 1 and 2.

The following is a rough guide to the difference in processing a bin
file against a text file:
   6K entries - x5
   4K entries - x4
   1K entries - x3
   500 entries - x2

[1] http://marc.info/?l=selinux&m=143101983922281&w=2
[2] http://marc.info/?l=selinux&m=143161763905159&w=2
[3] http://marc.info/?l=selinux&m=143204170705586&w=2

Signed-off-by: Richard Haines <richard_c_haines@btinternet.com>
2015-05-26 11:32:23 -04:00
..
include libselinux: add selinux_openssh_contexts_path() 2015-05-21 13:11:36 -04:00
man libselinux: matchpathcon/selabel_file: Fix man pages. 2015-05-11 09:53:37 -04:00
src Fix more bin file processing core dumps 2015-05-26 11:32:23 -04:00
utils libselinux: Ensure selabel_lookup_best_match links NULL terminated 2015-05-18 11:53:25 -04:00
ChangeLog Update libselinux ChangeLog. 2015-05-21 13:12:23 -04:00
LICENSE initial import from svn trunk revision 2950 2008-08-19 15:30:36 -04:00
Makefile libselinux: Refactor rpm_execcon() into a new setexecfilecon() 2014-01-06 14:06:03 -05:00
VERSION Bump to final release 2015-02-02 09:38:10 -05:00