1229fd05cSKees Cook=======
2229fd05cSKees CookSELinux
3229fd05cSKees Cook=======
4229fd05cSKees Cook
5229fd05cSKees CookIf you want to use SELinux, chances are you will want
6229fd05cSKees Cookto use the distro-provided policies, or install the
7229fd05cSKees Cooklatest reference policy release from
8229fd05cSKees Cook
90427612cSPetr Vorel	https://github.com/SELinuxProject/refpolicy
10229fd05cSKees Cook
11229fd05cSKees CookHowever, if you want to install a dummy policy for
12229fd05cSKees Cooktesting, you can do using ``mdp`` provided under
13229fd05cSKees Cookscripts/selinux.  Note that this requires the selinux
14229fd05cSKees Cookuserspace to be installed - in particular you will
15229fd05cSKees Cookneed checkpolicy to compile a kernel, and setfiles and
16229fd05cSKees Cookfixfiles to label the filesystem.
17229fd05cSKees Cook
18229fd05cSKees Cook	1. Compile the kernel with selinux enabled.
19229fd05cSKees Cook	2. Type ``make`` to compile ``mdp``.
20229fd05cSKees Cook	3. Make sure that you are not running with
21229fd05cSKees Cook	   SELinux enabled and a real policy.  If
22229fd05cSKees Cook	   you are, reboot with selinux disabled
23229fd05cSKees Cook	   before continuing.
24229fd05cSKees Cook	4. Run install_policy.sh::
25229fd05cSKees Cook
26229fd05cSKees Cook		cd scripts/selinux
27229fd05cSKees Cook		sh install_policy.sh
28229fd05cSKees Cook
29229fd05cSKees CookStep 4 will create a new dummy policy valid for your
30229fd05cSKees Cookkernel, with a single selinux user, role, and type.
31229fd05cSKees CookIt will compile the policy, will set your ``SELINUXTYPE`` to
32229fd05cSKees Cook``dummy`` in ``/etc/selinux/config``, install the compiled policy
33229fd05cSKees Cookas ``dummy``, and relabel your filesystem.
34