Getting help with supporting tools
There are tools out there that help in developing SELinux policies, and if needed we can build our own support tools as well. Let's see what support environments we can use.
Verifying code with selint
While SELinux policies can be functionally working, validating whether the code itself is proper and follows best practices is important to ensure that the code is maintainable in the long run.
One of the tools that support validating SELinux policy code is selint
, as offered from https://github.com/TresysTechnology/selint. Once built and installed, selint
offers insights into four main areas:
- Convention checks validate whether the SELinux policy follows the reference policy convention on how code should be structured and documented.
- Style checks give hints for code style that might be wrong, and where the developer might have intended a different behavior.
- Warnings are triggered when the code has bad calls that might trigger...