1secadm_selinux(8) secadm SELinux Policy documentation secadm_selinux(8)
2
3
4
6 secadm_r - Security administrator role - Security Enhanced Linux Policy
7
8
10 SELinux supports Roles Based Access Control (RBAC), some Linux roles
11 are login roles, while other roles need to be transition into.
12
13 Note: Examples in this man page will use the staff_u SELinux user.
14
15 Non login roles are usually used for administrative tasks. For example,
16 tasks that require root privileges. Roles control which types a user
17 can run processes with. Roles often have default types assigned to
18 them.
19
20 The default type for the secadm_r role is secadm_t.
21
22 The newrole program to transition directly to this role.
23
24 newrole -r secadm_r -t secadm_t
25
26 sudo is the preferred method to do transition from one role to another.
27 You setup sudo to transition to secadm_r by adding a similar line to
28 the /etc/sudoers file.
29
30 USERNAME ALL=(ALL) ROLE=secadm_r TYPE=secadm_t COMMAND
31
32 sudo will run COMMAND as staff_u:secadm_r:secadm_t:LEVEL
33
34 When using a non login role, you need to setup SELinux so that your
35 SELinux user can reach secadm_r role.
36
37 Execute the following to see all of the assigned SELinux roles:
38
39 semanage user -l
40
41 You need to add secadm_r to the staff_u user. You could setup the
42 staff_u user to be able to use the secadm_r role with a command like:
43
44 $ semanage user -m -R 'staff_r system_r secadm_r' staff_u
45
46
47
48 SELinux policy also controls which roles can transition to a different
49 role. You can list these rules using the following command.
50
51 search --role_allow
52
53 SELinux policy allows the sysadm_r, staff_r, auditadm_r roles can tran‐
54 sition to the secadm_r role.
55
56
57
59 SELinux policy is customizable based on least access required. secadm
60 policy is extremely flexible and has several booleans that allow you to
61 manipulate the policy and run secadm with the tightest access possible.
62
63
64
65 If you want to deny user domains applications to map a memory region as
66 both executable and writable, this is dangerous and the executable
67 should be reported in bugzilla, you must turn on the deny_execmem bool‐
68 ean. Disabled by default.
69
70 setsebool -P deny_execmem 1
71
72
73
74 If you want to deny any process from ptracing or debugging any other
75 processes, you must turn on the deny_ptrace boolean. Disabled by de‐
76 fault.
77
78 setsebool -P deny_ptrace 1
79
80
81
82 If you want to allow all domains to execute in fips_mode, you must turn
83 on the fips_mode boolean. Enabled by default.
84
85 setsebool -P fips_mode 1
86
87
88
89 If you want to allow system to run with NIS, you must turn on the
90 nis_enabled boolean. Disabled by default.
91
92 setsebool -P nis_enabled 1
93
94
95
96 If you want to allow unconfined executables to make their stack exe‐
97 cutable. This should never, ever be necessary. Probably indicates a
98 badly coded executable, but could indicate an attack. This executable
99 should be reported in bugzilla, you must turn on the selinuxuser_exec‐
100 stack boolean. Enabled by default.
101
102 setsebool -P selinuxuser_execstack 1
103
104
105
106 If you want to support NFS home directories, you must turn on the
107 use_nfs_home_dirs boolean. Disabled by default.
108
109 setsebool -P use_nfs_home_dirs 1
110
111
112
113 If you want to support SAMBA home directories, you must turn on the
114 use_samba_home_dirs boolean. Disabled by default.
115
116 setsebool -P use_samba_home_dirs 1
117
118
119
121 The SELinux process type secadm_t can manage files labeled with the
122 following file types. The paths listed are the default paths for these
123 file types. Note the processes UID still need to have DAC permissions.
124
125 boolean_type
126
127
128 default_context_t
129
130 /etc/selinux/([^/]*/)?contexts(/.*)?
131 /root/.default_contexts
132
133 dosfs_t
134
135
136 krb5_host_rcache_t
137
138 /var/tmp/krb5_0.rcache2
139 /var/cache/krb5rcache(/.*)?
140 /var/tmp/nfs_0
141 /var/tmp/DNS_25
142 /var/tmp/host_0
143 /var/tmp/imap_0
144 /var/tmp/HTTP_23
145 /var/tmp/HTTP_48
146 /var/tmp/ldap_55
147 /var/tmp/ldap_487
148 /var/tmp/ldapmap1_0
149
150 screen_home_t
151
152 /root/.screen(/.*)?
153 /home/[^/]+/.screen(/.*)?
154 /home/[^/]+/.screenrc
155 /home/[^/]+/.tmux.conf
156
157 security_t
158
159 /selinux
160
161 selinux_config_t
162
163 /etc/selinux(/.*)?
164 /etc/selinux/([^/]*/)?seusers
165 /etc/selinux/([^/]*/)?users(/.*)?
166 /etc/selinux/([^/]*/)?setrans.conf
167 /var/lib/sepolgen(/.*)?
168
169 selinux_login_config_t
170
171 /etc/selinux/([^/]*/)?logins(/.*)?
172
173 semanage_store_t
174
175 /etc/selinux/([^/]*/)?policy(/.*)?
176 /etc/selinux/(minimum|mls|targeted)/active(/.*)?
177 /etc/selinux/([^/]*/)?modules/(active|tmp|previous)(/.*)?
178 /var/lib/selinux(/.*)?
179 /etc/share/selinux/mls(/.*)?
180 /etc/share/selinux/targeted(/.*)?
181
182 systemd_passwd_var_run_t
183
184 /var/run/systemd/ask-password(/.*)?
185 /var/run/systemd/ask-password-block(/.*)?
186
187 user_tmp_type
188
189 all user tmp files
190
191
193 semanage fcontext can also be used to manipulate default file context
194 mappings.
195
196 semanage permissive can also be used to manipulate whether or not a
197 process type is permissive.
198
199 semanage module can also be used to enable/disable/install/remove pol‐
200 icy modules.
201
202 semanage boolean can also be used to manipulate the booleans
203
204
205 system-config-selinux is a GUI tool available to customize SELinux pol‐
206 icy settings.
207
208
210 This manual page was auto-generated using sepolicy manpage .
211
212
214 selinux(8), secadm(8), semanage(8), restorecon(8), chcon(1), sepol‐
215 icy(8), setsebool(8), secadm_screen_selinux(8),
216 secadm_screen_selinux(8), secadm_su_selinux(8), secadm_su_selinux(8),
217 secadm_sudo_selinux(8), secadm_sudo_selinux(8)
218
219
220
221mgrepl@redhat.com secadm secadm_selinux(8)