AA-GENPROF(8)
π AA-GENPROF(8) β your girl's guide to the AppArmor profile generation utility
okay bestie, so this is aa-genprof, straight out of the AppArmor manual, section 8 (that's the sysadmin-commands girlies π). it's the profile generation utility and honestly? it's iconic. let's get into it β¨
πΈ NAME πΈ
aa-genprof β the profile generation utility for AppArmor. that's the whole vibe. it makes profiles. it generates them. slay π
β¨ SYNOPSIS β¨
aa-genprof <executable> [-d /path/to/profiles] [-f /path/to/logfile]
that's it, that's the incantation πͺ
π OPTIONS π
-d,--dir/path/to/profilesβ tells her where the AppArmor security profile set lives. defaults to/etc/apparmor.dif you don't say anything, which is lowkey the main character location π-f,--file/path/to/logfileβ points at your logfile. the default locations get read from/etc/apparmor/logprof.conf, and the typical defaults are:
/var/log/audit/audit.log
/var/log/syslog
/var/log/messages
three options, all valid, all reading logs for you π«Ά
π DESCRIPTION π
so when you run aa-genprof, you must specify a program to profile. non-negotiable, bestie. and if the program you named isn't a fully-qualified path, aa-genprof will search $PATH to find it β she'll go looking for you, fr fr π
if a profile doesn't already exist for that program, aa-genprof creates one using aa-autodep(1). brand new profile, fresh out the box β¨
then genprof does her little routine:
- sets the profile to complain mode (she's being nice about it rn)
- writes a mark to the system log π
- instructs you, the user, to start the application you're profiling in another window and exercise its functionality β yes, actually use the app, go touch grass with it π±
after that, she presents you with two options: (S)can the system log for entries to add to the profile, or (F)inish.
if you pick (S)can or just hit return, aa-genprof parses the complain mode logs and iterates through the generated violations using aa-logprof(1). it's giving teamwork π€
once you're done selecting profile entries based on the violations detected during the program's execution, aa-genprof reloads the updated profiles in complain mode and asks you (S)can and (F)inish again. this cycle repeats as many times as you need until all the application functionality has been exercised without generating access violations. it's a loop, it's a lifestyle, it's fine π
and when you finally hit (F)inish? aa-genprof sets the main profile β plus any other profiles that were generated β into enforce mode and exits. periodt. π
π¦ BUGS π¦
found a bug? no cap, please report it at <https://gitlab.com/apparmor/apparmor/-/issues>. the girlies on the issue tracker will handle it π
π SEE ALSO π
apparmor(7), apparmor.d(5), aa-enforce(1), aa-complain(1), aa-disable(1), aa_change_hat(2), aa-logprof(1), logprof.conf(5), and <https://wiki.apparmor.net> β go read, iykyk π
ngl this one's a whole journey: complain mode β scan β repeat β enforce. trust the process, bestie π
and that's the page, bestie β brought to you by AppArmor 4.1.7, dated 2026-05-19. mwah, go profile something ππ
π¦ where this page comes from
- opensuse-leap 16.0: apparmor-utils 4.1.7-160000.2.1 Β· GPL-2.0-only AND LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms