1sanlock_selinux(8) SELinux Policy sanlock sanlock_selinux(8)
2
3
4
6 sanlock_selinux - Security Enhanced Linux Policy for the sanlock pro‐
7 cesses
8
10 Security-Enhanced Linux secures the sanlock processes via flexible
11 mandatory access control.
12
13 The sanlock processes execute with the sanlock_t SELinux type. You can
14 check if you have these processes running by executing the ps command
15 with the -Z qualifier.
16
17 For example:
18
19 ps -eZ | grep sanlock_t
20
21
22
24 The sanlock_t SELinux type can be entered via the sanlock_exec_t file
25 type.
26
27 The default entrypoint paths for the sanlock_t domain are the follow‐
28 ing:
29
30 /usr/sbin/sanlock
31
33 SELinux defines process types (domains) for each process running on the
34 system
35
36 You can see the context of a process using the -Z option to ps
37
38 Policy governs the access confined processes have to files. SELinux
39 sanlock policy is very flexible allowing users to setup their sanlock
40 processes in as secure a method as possible.
41
42 The following process types are defined for sanlock:
43
44 sanlock_t
45
46 Note: semanage permissive -a sanlock_t can be used to make the process
47 type sanlock_t permissive. SELinux does not deny access to permissive
48 process types, but the AVC (SELinux denials) messages are still gener‐
49 ated.
50
51
53 SELinux policy is customizable based on least access required. sanlock
54 policy is extremely flexible and has several booleans that allow you to
55 manipulate the policy and run sanlock with the tightest access possi‐
56 ble.
57
58
59
60 If you want to allow sanlock to read/write fuse files, you must turn on
61 the sanlock_use_fusefs boolean. Disabled by default.
62
63 setsebool -P sanlock_use_fusefs 1
64
65
66
67 If you want to allow sanlock to manage nfs files, you must turn on the
68 sanlock_use_nfs boolean. Disabled by default.
69
70 setsebool -P sanlock_use_nfs 1
71
72
73
74 If you want to allow sanlock to manage cifs files, you must turn on the
75 sanlock_use_samba boolean. Disabled by default.
76
77 setsebool -P sanlock_use_samba 1
78
79
80
81 If you want to allow all daemons to write corefiles to /, you must turn
82 on the allow_daemons_dump_core boolean. Disabled by default.
83
84 setsebool -P allow_daemons_dump_core 1
85
86
87
88 If you want to allow all daemons to use tcp wrappers, you must turn on
89 the allow_daemons_use_tcp_wrapper boolean. Disabled by default.
90
91 setsebool -P allow_daemons_use_tcp_wrapper 1
92
93
94
95 If you want to allow all daemons the ability to read/write terminals,
96 you must turn on the allow_daemons_use_tty boolean. Disabled by
97 default.
98
99 setsebool -P allow_daemons_use_tty 1
100
101
102
103 If you want to allow all domains to use other domains file descriptors,
104 you must turn on the allow_domain_fd_use boolean. Enabled by default.
105
106 setsebool -P allow_domain_fd_use 1
107
108
109
110 If you want to allow confined applications to run with kerberos, you
111 must turn on the allow_kerberos boolean. Enabled by default.
112
113 setsebool -P allow_kerberos 1
114
115
116
117 If you want to allow sysadm to debug or ptrace all processes, you must
118 turn on the allow_ptrace boolean. Disabled by default.
119
120 setsebool -P allow_ptrace 1
121
122
123
124 If you want to allow system to run with NIS, you must turn on the
125 allow_ypbind boolean. Disabled by default.
126
127 setsebool -P allow_ypbind 1
128
129
130
131 If you want to enable cluster mode for daemons, you must turn on the
132 daemons_enable_cluster_mode boolean. Disabled by default.
133
134 setsebool -P daemons_enable_cluster_mode 1
135
136
137
138 If you want to allow all domains to have the kernel load modules, you
139 must turn on the domain_kernel_load_modules boolean. Disabled by
140 default.
141
142 setsebool -P domain_kernel_load_modules 1
143
144
145
146 If you want to allow all domains to execute in fips_mode, you must turn
147 on the fips_mode boolean. Enabled by default.
148
149 setsebool -P fips_mode 1
150
151
152
153 If you want to enable reading of urandom for all domains, you must turn
154 on the global_ssp boolean. Disabled by default.
155
156 setsebool -P global_ssp 1
157
158
159
160 If you want to enable support for upstart as the init program, you must
161 turn on the init_upstart boolean. Enabled by default.
162
163 setsebool -P init_upstart 1
164
165
166
167 If you want to allow confined applications to use nscd shared memory,
168 you must turn on the nscd_use_shm boolean. Enabled by default.
169
170 setsebool -P nscd_use_shm 1
171
172
173
175 The SELinux process type sanlock_t can manage files labeled with the
176 following file types. The paths listed are the default paths for these
177 file types. Note the processes UID still need to have DAC permissions.
178
179 cifs_t
180
181
182 cluster_conf_t
183
184 /etc/cluster(/.*)?
185
186 cluster_var_lib_t
187
188 /var/lib(64)?/openais(/.*)?
189 /var/lib(64)?/pengine(/.*)?
190 /var/lib(64)?/corosync(/.*)?
191 /usr/lib(64)?/heartbeat(/.*)?
192 /var/lib(64)?/heartbeat(/.*)?
193 /var/lib(64)?/pacemaker(/.*)?
194 /var/lib/cluster(/.*)?
195
196 cluster_var_run_t
197
198 /var/run/crm(/.*)?
199 /var/run/cman_.*
200 /var/run/rsctmp(/.*)?
201 /var/run/aisexec.*
202 /var/run/heartbeat(/.*)?
203 /var/run/cpglockd.pid
204 /var/run/corosync.pid
205 /var/run/rgmanager.pid
206 /var/run/cluster/rgmanager.sk
207
208 fusefs_t
209
210
211 initrc_tmp_t
212
213
214 mnt_t
215
216 /mnt(/[^/]*)
217 /mnt(/[^/]*)?
218 /rhev(/[^/]*)?
219 /media(/[^/]*)
220 /media(/[^/]*)?
221 /etc/rhgb(/.*)?
222 /media/.hal-.*
223 /net
224 /afs
225 /rhev
226 /misc
227
228 nfs_t
229
230
231 root_t
232
233 /
234 /initrd
235
236 sanlock_log_t
237
238 /var/log/sanlock.log.*
239
240 sanlock_var_run_t
241
242 /var/run/sanlock(/.*)?
243
244 tmp_t
245
246 /tmp
247 /usr/tmp
248 /var/tmp
249 /tmp-inst
250 /var/tmp-inst
251 /var/tmp/vi.recover
252
253 virt_var_lib_t
254
255 /var/lib/oz(/.*)?
256 /var/lib/libvirt(/.*)?
257
258
260 SELinux requires files to have an extended attribute to define the file
261 type.
262
263 You can see the context of a file using the -Z option to ls
264
265 Policy governs the access confined processes have to these files.
266 SELinux sanlock policy is very flexible allowing users to setup their
267 sanlock processes in as secure a method as possible.
268
269 STANDARD FILE CONTEXT
270
271 SELinux defines the file context types for the sanlock, if you wanted
272 to store files with these types in a diffent paths, you need to execute
273 the semanage command to sepecify alternate labeling and then use
274 restorecon to put the labels on disk.
275
276 semanage fcontext -a -t sanlock_var_run_t '/srv/mysanlock_con‐
277 tent(/.*)?'
278 restorecon -R -v /srv/mysanlock_content
279
280 Note: SELinux often uses regular expressions to specify labels that
281 match multiple files.
282
283 The following file types are defined for sanlock:
284
285
286
287 sanlock_exec_t
288
289 - Set files with the sanlock_exec_t type, if you want to transition an
290 executable to the sanlock_t domain.
291
292
293
294 sanlock_initrc_exec_t
295
296 - Set files with the sanlock_initrc_exec_t type, if you want to transi‐
297 tion an executable to the sanlock_initrc_t domain.
298
299
300
301 sanlock_log_t
302
303 - Set files with the sanlock_log_t type, if you want to treat the data
304 as sanlock log data, usually stored under the /var/log directory.
305
306
307
308 sanlock_var_run_t
309
310 - Set files with the sanlock_var_run_t type, if you want to store the
311 sanlock files under the /run or /var/run directory.
312
313
314
315 Note: File context can be temporarily modified with the chcon command.
316 If you want to permanently change the file context you need to use the
317 semanage fcontext command. This will modify the SELinux labeling data‐
318 base. You will need to use restorecon to apply the labels.
319
320
322 semanage fcontext can also be used to manipulate default file context
323 mappings.
324
325 semanage permissive can also be used to manipulate whether or not a
326 process type is permissive.
327
328 semanage module can also be used to enable/disable/install/remove pol‐
329 icy modules.
330
331 semanage boolean can also be used to manipulate the booleans
332
333
334 system-config-selinux is a GUI tool available to customize SELinux pol‐
335 icy settings.
336
337
339 This manual page was auto-generated using sepolicy manpage .
340
341
343 selinux(8), sanlock(8), semanage(8), restorecon(8), chcon(1) , setse‐
344 bool(8)
345
346
347
348sanlock 15-06-03 sanlock_selinux(8)