SELinux

From 6bit.ch wiki
Revision as of 16:54, 7 May 2022 by Xbl (talk | contribs) (Created page with "= SELinux = == Available Commands == === Mode Management === <code>sestatus</code> show runtime status and boolean values (-b)</br> <code>getenforce</code> show current mode of operation</br> <code>setenforce</code> switch operating mode temporarily</br> === Context Management === <code>chcon</code> change file contexts (does not survive file system relabeling)</br> <code>restorecon</code> restore default file contexts, referencing /etc/selinux/targeted/contexts/fil...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

SELinux

Available Commands

Mode Management

sestatus show runtime status and boolean values (-b)
getenforce show current mode of operation
setenforce switch operating mode temporarily

Context Management

chcon change file contexts (does not survive file system relabeling)
restorecon restore default file contexts, referencing /etc/selinux/targeted/contexts/files
semanage fcontext change file contexts (survives file system relabeling)

Policy Management

seinfo show info about policy components
semanage manage policy database
sesearch search rules in policy database

Boolean Management

getsebool display booleans and their settings
setsebool modify booleans temporarily or in policy database
semanage boolean modify boolean values in policy database

Troubleshooting

sealert graphical troubleshooting tool