1dirsrv_selinux(8)            SELinux Policy dirsrv           dirsrv_selinux(8)
2
3
4

NAME

6       dirsrv_selinux  -  Security  Enhanced  Linux Policy for the dirsrv pro‐
7       cesses
8

DESCRIPTION

10       Security-Enhanced Linux  secures  the  dirsrv  processes  via  flexible
11       mandatory access control.
12
13       The  dirsrv  processes  execute with the dirsrv_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 dirsrv_t
20
21
22

ENTRYPOINTS

24       The  dirsrv_t  SELinux  type  can be entered via the dirsrv_exec_t file
25       type.
26
27       The default entrypoint paths for the dirsrv_t domain are the following:
28
29       /usr/sbin/ns-slapd
30

PROCESS TYPES

32       SELinux defines process types (domains) for each process running on the
33       system
34
35       You can see the context of a process using the -Z option to ps
36
37       Policy  governs  the  access confined processes have to files.  SELinux
38       dirsrv policy is very flexible allowing users  to  setup  their  dirsrv
39       processes in as secure a method as possible.
40
41       The following process types are defined for dirsrv:
42
43       dirsrvadmin_unconfined_script_t, dirsrv_snmp_t, dirsrvadmin_t, dirsrv_t
44
45       Note:  semanage  permissive -a dirsrv_t can be used to make the process
46       type dirsrv_t permissive. SELinux does not deny  access  to  permissive
47       process  types, but the AVC (SELinux denials) messages are still gener‐
48       ated.
49
50

BOOLEANS

52       SELinux policy is customizable based on least access required.   dirsrv
53       policy is extremely flexible and has several booleans that allow you to
54       manipulate the policy and run dirsrv with the tightest access possible.
55
56
57
58       If you want to allow all daemons to write corefiles to /, you must turn
59       on the allow_daemons_dump_core boolean. Disabled by default.
60
61       setsebool -P allow_daemons_dump_core 1
62
63
64
65       If  you want to allow all daemons to use tcp wrappers, you must turn on
66       the allow_daemons_use_tcp_wrapper boolean. Disabled by default.
67
68       setsebool -P allow_daemons_use_tcp_wrapper 1
69
70
71
72       If you want to allow all daemons the ability to  read/write  terminals,
73       you  must  turn  on  the  allow_daemons_use_tty  boolean.  Disabled  by
74       default.
75
76       setsebool -P allow_daemons_use_tty 1
77
78
79
80       If you want to allow all domains to use other domains file descriptors,
81       you must turn on the allow_domain_fd_use boolean. Enabled by default.
82
83       setsebool -P allow_domain_fd_use 1
84
85
86
87       If  you  want  to allow confined applications to run with kerberos, you
88       must turn on the allow_kerberos boolean. Enabled by default.
89
90       setsebool -P allow_kerberos 1
91
92
93
94       If you want to allow sysadm to debug or ptrace all processes, you  must
95       turn on the allow_ptrace boolean. Disabled by default.
96
97       setsebool -P allow_ptrace 1
98
99
100
101       If  you  want  to  allow  system  to run with NIS, you must turn on the
102       allow_ypbind boolean. Disabled by default.
103
104       setsebool -P allow_ypbind 1
105
106
107
108       If you want to enable cluster mode for daemons, you must  turn  on  the
109       daemons_enable_cluster_mode boolean. Disabled by default.
110
111       setsebool -P daemons_enable_cluster_mode 1
112
113
114
115       If  you  want to allow all domains to have the kernel load modules, you
116       must  turn  on  the  domain_kernel_load_modules  boolean.  Disabled  by
117       default.
118
119       setsebool -P domain_kernel_load_modules 1
120
121
122
123       If you want to allow all domains to execute in fips_mode, you must turn
124       on the fips_mode boolean. Enabled by default.
125
126       setsebool -P fips_mode 1
127
128
129
130       If you want to enable reading of urandom for all domains, you must turn
131       on the global_ssp boolean. Disabled by default.
132
133       setsebool -P global_ssp 1
134
135
136
137       If you want to enable support for upstart as the init program, you must
138       turn on the init_upstart boolean. Enabled by default.
139
140       setsebool -P init_upstart 1
141
142
143
144       If you want to allow confined applications to use nscd  shared  memory,
145       you must turn on the nscd_use_shm boolean. Enabled by default.
146
147       setsebool -P nscd_use_shm 1
148
149
150

MANAGED FILES

152       The  SELinux  process  type  dirsrv_t can manage files labeled with the
153       following file types.  The paths listed are the default paths for these
154       file types.  Note the processes UID still need to have DAC permissions.
155
156       cluster_conf_t
157
158            /etc/cluster(/.*)?
159
160       cluster_var_lib_t
161
162            /var/lib(64)?/openais(/.*)?
163            /var/lib(64)?/pengine(/.*)?
164            /var/lib(64)?/corosync(/.*)?
165            /usr/lib(64)?/heartbeat(/.*)?
166            /var/lib(64)?/heartbeat(/.*)?
167            /var/lib(64)?/pacemaker(/.*)?
168            /var/lib/cluster(/.*)?
169
170       cluster_var_run_t
171
172            /var/run/crm(/.*)?
173            /var/run/cman_.*
174            /var/run/rsctmp(/.*)?
175            /var/run/aisexec.*
176            /var/run/heartbeat(/.*)?
177            /var/run/cpglockd.pid
178            /var/run/corosync.pid
179            /var/run/rgmanager.pid
180            /var/run/cluster/rgmanager.sk
181
182       dirsrv_config_t
183
184            /etc/dirsrv(/.*)?
185
186       dirsrv_tmp_t
187
188
189       dirsrv_tmpfs_t
190
191
192       dirsrv_var_lib_t
193
194            /var/lib/dirsrv(/.*)?
195
196       dirsrv_var_lock_t
197
198            /var/lock/dirsrv(/.*)?
199            /var/lock/subsys/dirsrv
200            /var/lock/subsys/dirsrv-admin
201
202       dirsrv_var_log_t
203
204            /var/log/dirsrv(/.*)?
205
206       dirsrv_var_run_t
207
208            /var/run/slapd.*
209            /var/run/dirsrv(/.*)?
210
211       dirsrvadmin_tmp_t
212
213
214       faillog_t
215
216            /var/log/btmp.*
217            /var/log/faillog.*
218            /var/log/tallylog.*
219            /var/run/faillock(/.*)?
220
221       initrc_tmp_t
222
223
224       krb5_host_rcache_t
225
226            /var/cache/krb5rcache(/.*)?
227            /var/tmp/host_0
228            /var/tmp/HTTP_23
229
230       lastlog_t
231
232            /var/log/lastlog.*
233
234       mnt_t
235
236            /mnt(/[^/]*)
237            /mnt(/[^/]*)?
238            /rhev(/[^/]*)?
239            /media(/[^/]*)
240            /media(/[^/]*)?
241            /etc/rhgb(/.*)?
242            /media/.hal-.*
243            /net
244            /afs
245            /rhev
246            /misc
247
248       pcscd_var_run_t
249
250            /var/run/pcscd.events(/.*)?
251            /var/run/pcscd.pid
252            /var/run/pcscd.pub
253            /var/run/pcscd.comm
254
255       root_t
256
257            /
258            /initrd
259
260       security_t
261
262
263       tmp_t
264
265            /tmp
266            /usr/tmp
267            /var/tmp
268            /tmp-inst
269            /var/tmp-inst
270            /var/tmp/vi.recover
271
272

FILE CONTEXTS

274       SELinux requires files to have an extended attribute to define the file
275       type.
276
277       You can see the context of a file using the -Z option to ls
278
279       Policy governs the access  confined  processes  have  to  these  files.
280       SELinux  dirsrv  policy  is very flexible allowing users to setup their
281       dirsrv processes in as secure a method as possible.
282
283       EQUIVALENCE DIRECTORIES
284
285
286       dirsrv policy stores data with multiple different  file  context  types
287       under  the  /var/log/dirsrv  directory.  If you would like to store the
288       data in a different directory you can use the semanage command to  cre‐
289       ate an equivalence mapping.  If you wanted to store this data under the
290       /srv dirctory you would execute the following command:
291
292       semanage fcontext -a -e /var/log/dirsrv /srv/dirsrv
293       restorecon -R -v /srv/dirsrv
294
295       STANDARD FILE CONTEXT
296
297       SELinux defines the file context types for the dirsrv, if you wanted to
298       store  files  with  these types in a diffent paths, you need to execute
299       the semanage command  to  sepecify  alternate  labeling  and  then  use
300       restorecon to put the labels on disk.
301
302       semanage fcontext -a -t dirsrvadmin_tmp_t '/srv/mydirsrv_content(/.*)?'
303       restorecon -R -v /srv/mydirsrv_content
304
305       Note:  SELinux  often  uses  regular expressions to specify labels that
306       match multiple files.
307
308       The following file types are defined for dirsrv:
309
310
311
312       dirsrv_config_t
313
314       - Set files with the dirsrv_config_t type, if you  want  to  treat  the
315       files  as  dirsrv  configuration  data,  usually  stored under the /etc
316       directory.
317
318
319
320       dirsrv_exec_t
321
322       - Set files with the dirsrv_exec_t type, if you want to  transition  an
323       executable to the dirsrv_t domain.
324
325
326
327       dirsrv_share_t
328
329       -  Set  files  with  the  dirsrv_share_t type, if you want to treat the
330       files as dirsrv share data.
331
332
333
334       dirsrv_snmp_exec_t
335
336       - Set files with the dirsrv_snmp_exec_t type, if you want to transition
337       an executable to the dirsrv_snmp_t domain.
338
339
340
341       dirsrv_snmp_var_log_t
342
343       -  Set  files with the dirsrv_snmp_var_log_t type, if you want to treat
344       the data as dirsrv snmp var log data, usually stored under the /var/log
345       directory.
346
347
348
349       dirsrv_snmp_var_run_t
350
351       -  Set  files with the dirsrv_snmp_var_run_t type, if you want to store
352       the dirsrv snmp files under the /run or /var/run directory.
353
354
355
356       dirsrv_tmp_t
357
358       - Set files with the dirsrv_tmp_t type, if you  want  to  store  dirsrv
359       temporary files in the /tmp directories.
360
361
362
363       dirsrv_tmpfs_t
364
365       -  Set  files with the dirsrv_tmpfs_t type, if you want to store dirsrv
366       files on a tmpfs file system.
367
368
369
370       dirsrv_var_lib_t
371
372       - Set files with the dirsrv_var_lib_t type, if you want  to  store  the
373       dirsrv files under the /var/lib directory.
374
375
376
377       dirsrv_var_lock_t
378
379       -  Set  files with the dirsrv_var_lock_t type, if you want to treat the
380       files as dirsrv var lock data, stored under the /var/lock directory
381
382
383       Paths:
384            /var/lock/dirsrv(/.*)?,  /var/lock/subsys/dirsrv,   /var/lock/sub‐
385            sys/dirsrv-admin
386
387
388       dirsrv_var_log_t
389
390       -  Set  files  with the dirsrv_var_log_t type, if you want to treat the
391       data as dirsrv var log data, usually stored under the  /var/log  direc‐
392       tory.
393
394
395
396       dirsrv_var_run_t
397
398       -  Set  files  with the dirsrv_var_run_t type, if you want to store the
399       dirsrv files under the /run or /var/run directory.
400
401
402       Paths:
403            /var/run/slapd.*, /var/run/dirsrv(/.*)?
404
405
406       dirsrvadmin_config_t
407
408       - Set files with the dirsrvadmin_config_t type, if you  want  to  treat
409       the  files  as dirsrvadmin configuration data, usually stored under the
410       /etc directory.
411
412
413       Paths:
414            /etc/dirsrv/dsgw(/.*)?, /etc/dirsrv/admin-serv(/.*)?
415
416
417       dirsrvadmin_exec_t
418
419       - Set files with the dirsrvadmin_exec_t type, if you want to transition
420       an executable to the dirsrvadmin_t domain.
421
422
423       Paths:
424            /usr/sbin/stop-ds-admin,                 /usr/sbin/start-ds-admin,
425            /usr/sbin/restart-ds-admin
426
427
428       dirsrvadmin_tmp_t
429
430       - Set files with the dirsrvadmin_tmp_t  type,  if  you  want  to  store
431       dirsrvadmin temporary files in the /tmp directories.
432
433
434
435       dirsrvadmin_unconfined_script_exec_t
436
437       -  Set files with the dirsrvadmin_unconfined_script_exec_t type, if you
438       want to transition an executable to the dirsrvadmin_unconfined_script_t
439       domain.
440
441
442       Paths:
443            /usr/lib(64)?/dirsrv/cgi-bin/ds_create,  /usr/lib(64)?/dirsrv/cgi-
444            bin/ds_remove
445
446
447       Note: File context can be temporarily modified with the chcon  command.
448       If  you want to permanently change the file context you need to use the
449       semanage fcontext command.  This will modify the SELinux labeling data‐
450       base.  You will need to use restorecon to apply the labels.
451
452

COMMANDS

454       semanage  fcontext  can also be used to manipulate default file context
455       mappings.
456
457       semanage permissive can also be used to manipulate  whether  or  not  a
458       process type is permissive.
459
460       semanage  module can also be used to enable/disable/install/remove pol‐
461       icy modules.
462
463       semanage boolean can also be used to manipulate the booleans
464
465
466       system-config-selinux is a GUI tool available to customize SELinux pol‐
467       icy settings.
468
469

AUTHOR

471       This manual page was auto-generated using sepolicy manpage .
472
473

SEE ALSO

475       selinux(8),  dirsrv(8),  semanage(8),  restorecon(8), chcon(1) , setse‐
476       bool(8), dirsrv_snmp_selinux(8), dirsrv_snmp_selinux(8)
477
478
479
480dirsrv                             15-06-03                  dirsrv_selinux(8)
Impressum