AppArmor
Official Website | Docs | Wiki
Install the apparmor-utils package as well
Some common commands are:
aa-enabled: Is apparmor enabled or notaa-status: Display the status of profile enforcementaa-genprof: Create an apparmor profileaa-logprof: Update and existing profileaa-complain: Set a profile in complain modeaa-enforce: Set a profile in enforce modeapparmor_parser <-r|-a> /path/to/profileto reload or add a profile
A profile in apparmor can run in various modes:
complain: Apparmor allows a process to perform almost all tasks but will log them as events in the audit log. It will still enforce any explicit deny rules in a profile.unconfined: Allows a program to perform any task and will not log itenforced: Apparmor enforces the rules specified in the profile
Common apparmor permissions
r: readw: writek: lockux: unconstrained executeUx: unconstrained execute -scrubpx: discrete profile executePx: discrete profile execute -scrubix: inherit executecx: local seecurity profilel: linka: appendm: memory map
Apparmor profiles are stored in /etc/apparmor.d by default
It also adds the -Z option to commands like ps to show what profile is being
used in different applications and in what mode