Linux command
getsebool 命令
网络
复制后可按需替换文件名、目录或参数。
常用示例
Example
getsebool httpd_can_connect_ftp
Example
getsebool -a
Example
sudo semanage boolean -l
说明
getsebool retrieves the current value of SELinux booleans. SELinux booleans are on/off switches that modify SELinux policy behavior at runtime without requiring policy recompilation. Booleans control specific policy features like whether Apache can connect to external networks (httpd_can_network_connect), whether users can run unconfined processes, or whether certain services can access home directories. Output shows the boolean name and its current state (on/off). Use setsebool to change values.
参数
- -a
- List all SELinux booleans and their current values
- boolean
- Name of specific boolean to query
FAQ
What is the getsebool command used for?
getsebool retrieves the current value of SELinux booleans. SELinux booleans are on/off switches that modify SELinux policy behavior at runtime without requiring policy recompilation. Booleans control specific policy features like whether Apache can connect to external networks (httpd_can_network_connect), whether users can run unconfined processes, or whether certain services can access home directories. Output shows the boolean name and its current state (on/off). Use setsebool to change values.
How do I run a basic getsebool example?
Run `getsebool httpd_can_connect_ftp` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -a do in getsebool?
List all SELinux booleans and their current values