kiwi_selinux(8)
π kiwi_selinux(8) β the SELinux policy page for kiwi, bestie
okay so this is kiwi_selinux, the manual page for the SELinux policy that governs the kiwi processes. yes it's a whole policy page. yes it's iconic. let's go β¨
πΈ NAME πΈ
kiwi_selinux β Security Enhanced Linux Policy for the kiwi processes π«Ά
π¦ DESCRIPTION π¦
Security-Enhanced Linux secures the kiwi processes via flexible mandatory access control. that's the whole vibe β SELinux is the main character here and it's not letting kiwi run around doing whatever it wants. no cap.
the kiwi processes execute with the kiwi_t SELinux type. wanna check if you've got these processes running? literally just run the ps command with the -Z qualifier. like so:
ps -eZ | grep kiwi_t
and that's it. that's the vibe check π
π ENTRYPOINTS π
so the kiwi_t SELinux type can be entered via the kiwi_exec_t file type. that's the doorway, bestie.
the default entrypoint paths for the kiwi_t domain are:
/usr/bin/kiwi-ng
that's the one. the only one. periodt.
π₯ PROCESS TYPES π₯
SELinux defines process types (domains) for each process running on the system. yes, every single one. it's giving organized.
you can see the context of a process using the -Z option to ps β¨
policy governs the access confined processes have to files. SELinux kiwi policy is very flexible β it lets users set up their kiwi processes in as secure a method as possible. like, you get the security and the flexibility. obsessed.
the following process types are defined for kiwi:
kiwi_t
Note:semanage permissive -a kiwi_tcan be used to make the process typekiwi_tpermissive. SELinux does not deny access to permissive process types, but the AVC (SELinux denials) messages are still generated. so like, it stops blocking things but it's still gonna be posting receipts in the log. iykyk π
π BOOLEANS π
SELinux policy is customizable based on least access required. kiwi policy is extremely flexible and has several booleans that let you manipulate the policy and run kiwi with the tightest access possible. tightest access = the goal, fr fr.
if you want to deny user domains applications to map a memory region as both executable and writable β which is dangerous and the executable should be reported in bugzilla β you must turn on the deny_execmem boolean. disabled by default.
setsebool -P deny_execmem 1
if you want to control the ability to mmap a low area of the address space, as configured by /proc/sys/vm/mmap_min_addr, you must turn on the mmap_low_allowed boolean. disabled by default.
setsebool -P mmap_low_allowed 1
if you want to disable kernel module loading, you must turn on the secure_mode_insmod boolean. disabled by default.
setsebool -P secure_mode_insmod 1
if you want to allow unconfined executables to make their heap memory executable β doing this is a really bad idea π probably indicates a badly coded executable, but could indicate an attack, and the executable should be reported in bugzilla β you must turn on the selinuxuser_execheap boolean. disabled by default.
setsebool -P selinuxuser_execheap 1
if you want to allow unconfined executables to make their stack executable β this should never, ever be necessary, probably indicates a badly coded executable, but could indicate an attack, and the executable should be reported in bugzilla β you must turn on the selinuxuser_execstack boolean. disabled by default.
setsebool -P selinuxuser_execstack 1
like bestie i'm begging you, read those warnings before you flip those booleans π dangerous stuff is dangerous, that part did not change just because i said it cutely.
π MANAGED FILES π
the SELinux process type kiwi_t can manage files labeled with the following file types. the paths listed are the default paths for these file types. note: the process's UID still needs to have DAC permissions. SELinux don't override that, no ma'am.
file_type- all files on the system
that's right. all of them. the whole system. iconic scope, honestly π
π§ FILE CONTEXTS π§
SELinux requires files to have an extended attribute to define the file type. that's just how it is.
you can see the context of a file using the -Z option to ls β¨
policy governs the access confined processes have to these files. SELinux kiwi policy is very flexible, allowing users to set up their kiwi processes in as secure a method as possible. we love a flexible queen π
β STANDARD FILE CONTEXT β
SELinux defines the file context types for the kiwi. if you wanted to store files with these types in different paths, you need to execute the semanage command to specify alternate labeling, and then use restorecon to put the labels on disk. two-step process, both steps mandatory, don't skip π
semanage fcontext -a -t kiwi_exec_t '/srv/kiwi/content(/.*)?'
restorecon -R -v /srv/mykiwi_content
Note: SELinux often uses regular expressions to specify labels that match multiple files. regex my beloved π
the following file types are defined for kiwi:
kiwi_exec_tβ set files with thekiwi_exec_ttype if you want to transition an executable to thekiwi_tdomain.
Note: file context can be temporarily modified with thechconcommand. if you want to permanently change the file context you need to use thesemanage fcontextcommand β this will modify the SELinux labeling database. you will need to userestoreconto apply the labels. sochconis the quick fix andsemanage fcontext+restoreconis the forever fix. know the difference bestie π«Ά
π COMMANDS π
semanage fcontextcan also be used to manipulate default file context mappings.semanage permissivecan also be used to manipulate whether or not a process type is permissive.semanage modulecan also be used to enable/disable/install/remove policy modules.semanage booleancan also be used to manipulate the booleans.system-config-selinuxis a GUI tool available to customize SELinux policy settings. yes, a GUI. for the girlies who prefer clicking π±οΈβ¨
π AUTHOR π
this manual page was auto-generated using sepolicy manpage. shoutout to the robot that wrote it π€π
π SEE ALSO π
selinux(8), kiwi(8), semanage(8), restorecon(8), chcon(1), sepolicy(8), setsebool(8)
and that's the whole page, bestie π this was kiwi, version 26-10-06, under kiwi_selinux(8). go forth and label responsibly π
β¨
π¦ where this page comes from
- opensuse-leap 16.0: selinux-policy-doc 20250627+git412.dbf877ab7-160000.1.1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms