-
Notifications
You must be signed in to change notification settings - Fork 67
SETools 4 on Ubuntu 15
bergtian edited this page Mar 14, 2016
·
7 revisions
This doc describes how to install setools 4 on ubuntu 15.10 with python2.7.
$ sudo apt-get install bison flex libsepol swig gcc libbz2-dev mock
$ sudo apt-get install libsepol1-dev sepol-utils libselinux1-dev selinux-utils libselinux1
$ sudo apt-get install python-PyQt5 python-selinux python-setools python-mock
$ sudo pip install networkx python2.7-dev
if you want to pass all tests, you should install libsepol from sourcecode and apply libsepol-2.4-mls-semantic-level-expand.patch.
you can apply the patch simply:
$ patch -p1 < patches/use-libsepol-2.3.diff
or just modify the struct class_perm_node in policydb.h
typedef struct class_perm_node {
uint32_t tclass; //orign: uint32_t class;
uint32_t data; /* permissions or new type */
struct class_perm_node *next;
} class_perm_node_t;
export SEPOL=/usr/lib/x86_64-linux-gnu/libsepol.a
python setup.py build
sudo -E python setup.py install