1xdm_selinux(8)                SELinux Policy xdm                xdm_selinux(8)
2
3
4

NAME

6       xdm_selinux - Security Enhanced Linux Policy for the xdm processes
7

DESCRIPTION

9       Security-Enhanced  Linux  secures the xdm processes via flexible manda‐
10       tory access control.
11
12       The xdm processes execute with the xdm_t SELinux type. You can check if
13       you  have  these processes running by executing the ps command with the
14       -Z qualifier.
15
16       For example:
17
18       ps -eZ | grep xdm_t
19
20
21

ENTRYPOINTS

23       The xdm_t SELinux type can be entered via  the  user_tmp_t,  xdm_exec_t
24       file types.
25
26       The default entrypoint paths for the xdm_t domain are the following:
27
28       /dev/shm/mono.*,       /var/run/user/[^/]+,       /tmp/.ICE-unix(/.*)?,
29       /tmp/.X11-unix(/.*)?,       /dev/shm/pulse-shm.*,        /tmp/.X0-lock,
30       /var/run/user,      /tmp/hsperfdata_root,     /var/tmp/hsperfdata_root,
31       /home/[^/]+/tmp,        /home/[^/]+/.tmp,         /var/run/user/[0-9]+,
32       /tmp/gconfd-[^/]+,         /usr/s?bin/nodm,         /usr/s?bin/gdm(3)?,
33       /usr/s?bin/lightdm*,    /usr/s?bin/[mxgkw]dm,    /usr/s?bin/gdm-binary,
34       /usr/s?bin/lxdm(-binary)?,   /usr/X11R6/bin/[xgkw]dm,   /usr/bin/razor-
35       lightdm-.*,     /usr/bin/sddm,     /usr/bin/slim,      /usr/bin/gpe-dm,
36       /opt/kde3/bin/kdm,     /usr/sbin/mdm-binary,     /usr/bin/sddm-greeter,
37       /etc/rc.d/init.d/x11-common,           /usr/libexec/gdm-runtime-config,
38       /usr/libexec/gdm-disable-wayland
39

PROCESS TYPES

41       SELinux defines process types (domains) for each process running on the
42       system
43
44       You can see the context of a process using the -Z option to ps
45
46       Policy governs the access confined processes have  to  files.   SELinux
47       xdm policy is very flexible allowing users to setup their xdm processes
48       in as secure a method as possible.
49
50       The following process types are defined for xdm:
51
52       xdm_t, xdm_unconfined_t
53
54       Note: semanage permissive -a xdm_t can be used to make the process type
55       xdm_t  permissive.  SELinux  does not deny access to permissive process
56       types, but the AVC (SELinux denials) messages are still generated.
57
58

BOOLEANS

60       SELinux policy is customizable based on  least  access  required.   xdm
61       policy is extremely flexible and has several booleans that allow you to
62       manipulate the policy and run xdm with the tightest access possible.
63
64
65
66       If you want to allows xdm_t to bind on vnc_port_t(5910), you must  turn
67       on the xdm_bind_vnc_tcp_port boolean. Disabled by default.
68
69       setsebool -P xdm_bind_vnc_tcp_port 1
70
71
72
73       If  you  want  to  allow  the  graphical login program to create, read,
74       write, and delete files in the /boot director and DOS  filesystem,  you
75       must turn on the xdm_manage_bootloader boolean. Enabled by default.
76
77       setsebool -P xdm_manage_bootloader 1
78
79
80
81       If  you  want to allow the graphical login program to login directly as
82       sysadm_r:sysadm_t, you must turn on the xdm_sysadm_login boolean.  Dis‐
83       abled by default.
84
85       setsebool -P xdm_sysadm_login 1
86
87
88
89       If you want to deny user domains applications to map a memory region as
90       both executable and writable, this  is  dangerous  and  the  executable
91       should be reported in bugzilla, you must turn on the deny_execmem bool‐
92       ean. Disabled by default.
93
94       setsebool -P deny_execmem 1
95
96
97
98       If you want to deny any process from ptracing or  debugging  any  other
99       processes,  you  must  turn on the deny_ptrace boolean. Disabled by de‐
100       fault.
101
102       setsebool -P deny_ptrace 1
103
104
105
106       If you want to allow all domains to execute in fips_mode, you must turn
107       on the fips_mode boolean. Enabled by default.
108
109       setsebool -P fips_mode 1
110
111
112
113       If  you  want  to allow confined applications to run with kerberos, you
114       must turn on the kerberos_enabled boolean. Enabled by default.
115
116       setsebool -P kerberos_enabled 1
117
118
119
120       If you want to allow system to run with  NIS,  you  must  turn  on  the
121       nis_enabled boolean. Disabled by default.
122
123       setsebool -P nis_enabled 1
124
125
126
127       If you want to enable polyinstantiated directory support, you must turn
128       on the polyinstantiation_enabled boolean. Disabled by default.
129
130       setsebool -P polyinstantiation_enabled 1
131
132
133
134       If you want to allow unconfined executables to make  their  stack  exe‐
135       cutable.   This  should  never, ever be necessary. Probably indicates a
136       badly coded executable, but could indicate an attack.  This  executable
137       should  be reported in bugzilla, you must turn on the selinuxuser_exec‐
138       stack boolean. Enabled by default.
139
140       setsebool -P selinuxuser_execstack 1
141
142
143
144       If you want to support ecryptfs home directories, you must turn on  the
145       use_ecryptfs_home_dirs boolean. Disabled by default.
146
147       setsebool -P use_ecryptfs_home_dirs 1
148
149
150
151       If  you  want  to support fusefs home directories, you must turn on the
152       use_fusefs_home_dirs boolean. Disabled by default.
153
154       setsebool -P use_fusefs_home_dirs 1
155
156
157
158       If you want to support NFS home  directories,  you  must  turn  on  the
159       use_nfs_home_dirs boolean. Disabled by default.
160
161       setsebool -P use_nfs_home_dirs 1
162
163
164
165       If  you  want  to  support SAMBA home directories, you must turn on the
166       use_samba_home_dirs boolean. Disabled by default.
167
168       setsebool -P use_samba_home_dirs 1
169
170
171

PORT TYPES

173       SELinux defines port types to represent TCP and UDP ports.
174
175       You can see the types associated with a port  by  using  the  following
176       command:
177
178       semanage port -l
179
180
181       Policy  governs  the  access  confined  processes  have to these ports.
182       SELinux xdm policy is very flexible allowing users to setup  their  xdm
183       processes in as secure a method as possible.
184
185       The following port types are defined for xdm:
186
187
188       xdmcp_port_t
189
190
191
192       Default Defined Ports:
193                 tcp 177
194                 udp 177
195

MANAGED FILES

197       The  SELinux  process type xdm_t can manage files labeled with the fol‐
198       lowing file types.  The paths listed are the default  paths  for  these
199       file types.  Note the processes UID still need to have DAC permissions.
200
201       auth_cache_t
202
203            /var/cache/coolkey(/.*)?
204
205       auth_home_t
206
207            /root/.yubico(/.*)?
208            /root/.config/Yubico(/.*)?
209            /root/.google_authenticator
210            /root/.google_authenticator~
211            /home/[^/]+/.yubico(/.*)?
212            /home/[^/]+/.config/Yubico(/.*)?
213            /home/[^/]+/.google_authenticator
214            /home/[^/]+/.google_authenticator~
215
216       cifs_t
217
218
219       dosfs_t
220
221
222       faillog_t
223
224            /var/log/btmp.*
225            /var/log/faillog.*
226            /var/log/tallylog.*
227            /var/run/faillock(/.*)?
228
229       fusefs_t
230
231            /var/run/user/[0-9]+/gvfs
232
233       gnome_initial_setup_var_lib_t
234
235            /var/lib/gnome-initial-setup(/.*)?
236
237       gnome_initial_setup_var_run_t
238
239            /var/run/gnome-initial-setup(/.*)?
240
241       initrc_var_run_t
242
243            /var/run/utmp
244            /var/run/random-seed
245            /var/run/runlevel.dir
246            /var/run/setmixer_flag
247
248       krb5_host_rcache_t
249
250            /var/tmp/krb5_0.rcache2
251            /var/cache/krb5rcache(/.*)?
252            /var/tmp/nfs_0
253            /var/tmp/DNS_25
254            /var/tmp/host_0
255            /var/tmp/imap_0
256            /var/tmp/HTTP_23
257            /var/tmp/HTTP_48
258            /var/tmp/ldap_55
259            /var/tmp/ldap_487
260            /var/tmp/ldapmap1_0
261
262       lastlog_t
263
264            /var/log/lastlog.*
265
266       nfs_t
267
268
269       pam_var_console_t
270
271            /var/run/console(/.*)?
272
273       pam_var_run_t
274
275            /var/(db|adm)/sudo(/.*)?
276            /var/lib/sudo(/.*)?
277            /var/run/sudo(/.*)?
278            /var/run/pam_ssh(/.*)?
279            /var/run/sepermit(/.*)?
280            /var/run/pam_mount(/.*)?
281            /var/run/pam_timestamp(/.*)?
282
283       security_t
284
285            /selinux
286
287       sysfs_t
288
289            /sys(/.*)?
290
291       systemd_passwd_var_run_t
292
293            /var/run/systemd/ask-password(/.*)?
294            /var/run/systemd/ask-password-block(/.*)?
295
296       tmpfs_t
297
298            /dev/shm
299            /var/run/shm
300            /usr/lib/udev/devices/shm
301
302       user_tmp_t
303
304            /dev/shm/mono.*
305            /var/run/user/[^/]+
306            /tmp/.ICE-unix(/.*)?
307            /tmp/.X11-unix(/.*)?
308            /dev/shm/pulse-shm.*
309            /tmp/.X0-lock
310            /var/run/user
311            /tmp/hsperfdata_root
312            /var/tmp/hsperfdata_root
313            /home/[^/]+/tmp
314            /home/[^/]+/.tmp
315            /var/run/user/[0-9]+
316            /tmp/gconfd-[^/]+
317
318       user_tmp_type
319
320            all user tmp files
321
322       var_auth_t
323
324            /var/ace(/.*)?
325            /var/rsa(/.*)?
326            /var/lib/abl(/.*)?
327            /var/lib/rsa(/.*)?
328            /var/lib/pam_ssh(/.*)?
329            /var/lib/pam_shield(/.*)?
330            /var/opt/quest/vas/vasd(/.*)?
331            /var/lib/google-authenticator(/.*)?
332
333       wtmp_t
334
335            /var/log/wtmp.*
336
337       xdm_lock_t
338
339
340       xdm_log_t
341
342            /var/log/[mkwx]dm.log.*
343            /var/log/mdm(/.*)?
344            /var/log/lxdm.log.*
345            /var/log/slim.log.*
346
347       xdm_spool_t
348
349            /var/spool/[mg]dm(/.*)?
350
351       xdm_tmpfs_t
352
353
354       xdm_var_lib_t
355
356            /var/lib/[mxkwg]dm(/.*)?
357            /var/cache/[mg]dm(/.*)?
358            /var/lib/gdm(3)?(/.*)?
359            /var/lib/lxdm(/.*)?
360            /var/lib/sddm(/.*)?
361            /var/lib/lightdm(/.*)?
362            /var/cache/lightdm(/.*)?
363            /var/lib/lightdm-data(/.*)?
364
365       xdm_var_run_t
366
367            /etc/kde[34]?/kdm/backgroundrc
368            /var/run/[kgm]dm(/.*)?
369            /var/run/gdm(3)?.pid
370            /var/run/gdm(3)?(/.*)?
371            /usr/lib/qt-.*/etc/settings(/.*)?
372            /var/run/slim.*
373            /var/run/lxdm(/.*)?
374            /var/run/sddm(/.*)?
375            /var/run/xauth(/.*)?
376            /var/run/xdmctl(/.*)?
377            /var/run/lightdm(/.*)?
378            /var/run/systemd/multi-session-x(/.*)?
379            /var/run/xdm.pid
380            /var/run/lxdm.pid
381            /var/run/lxdm.auth
382            /var/run/gdm_socket
383
384       xkb_var_lib_t
385
386            /var/lib/xkb(/.*)?
387            /usr/X11R6/lib/X11/xkb/.*
388            /usr/X11R6/lib/X11/xkb
389
390       xserver_log_t
391
392            /var/[xgkw]dm(/.*)?
393            /usr/var/[xgkw]dm(/.*)?
394            /var/log/gdm(3)?(/.*)?
395            /var/log/Xorg.*
396            /var/log/XFree86.*
397            /var/log/lightdm(/.*)?
398            /var/log/nvidia-installer.log.*
399
400       xserver_tmpfs_t
401
402
403

FILE CONTEXTS

405       SELinux requires files to have an extended attribute to define the file
406       type.
407
408       You can see the context of a file using the -Z option to ls
409
410       Policy governs the access  confined  processes  have  to  these  files.
411       SELinux  xdm  policy is very flexible allowing users to setup their xdm
412       processes in as secure a method as possible.
413
414       EQUIVALENCE DIRECTORIES
415
416
417       xdm policy stores data with multiple different file context types under
418       the /var/lib/lightdm directory.  If you would like to store the data in
419       a different directory you can use the semanage  command  to  create  an
420       equivalence  mapping.   If you wanted to store this data under the /srv
421       directory you would execute the following command:
422
423       semanage fcontext -a -e /var/lib/lightdm /srv/lightdm
424       restorecon -R -v /srv/lightdm
425
426       xdm policy stores data with multiple different file context types under
427       the /var/run/gdm(3)? directory.  If you would like to store the data in
428       a different directory you can use the semanage  command  to  create  an
429       equivalence  mapping.   If you wanted to store this data under the /srv
430       directory you would execute the following command:
431
432       semanage fcontext -a -e /var/run/gdm(3)? /srv/gdm(3)?
433       restorecon -R -v /srv/gdm(3)?
434
435       xdm policy stores data with multiple different file context types under
436       the  /var/run/lxdm directory.  If you would like to store the data in a
437       different directory you can use  the  semanage  command  to  create  an
438       equivalence  mapping.   If you wanted to store this data under the /srv
439       directory you would execute the following command:
440
441       semanage fcontext -a -e /var/run/lxdm /srv/lxdm
442       restorecon -R -v /srv/lxdm
443
444       STANDARD FILE CONTEXT
445
446       SELinux defines the file context types for the xdm, if  you  wanted  to
447       store  files with these types in a different paths, you need to execute
448       the semanage command to specify alternate labeling  and  then  use  re‐
449       storecon to put the labels on disk.
450
451       semanage fcontext -a -t xdm_unconfined_exec_t '/srv/xdm/content(/.*)?'
452       restorecon -R -v /srv/myxdm_content
453
454       Note:  SELinux  often  uses  regular expressions to specify labels that
455       match multiple files.
456
457       The following file types are defined for xdm:
458
459
460
461       xdm_etc_t
462
463       - Set files with the xdm_etc_t type, if you want to store xdm files  in
464       the /etc directories.
465
466
467
468       xdm_exec_t
469
470       - Set files with the xdm_exec_t type, if you want to transition an exe‐
471       cutable to the xdm_t domain.
472
473
474       Paths:
475            /usr/s?bin/nodm,     /usr/s?bin/gdm(3)?,      /usr/s?bin/lightdm*,
476            /usr/s?bin/[mxgkw]dm,  /usr/s?bin/gdm-binary, /usr/s?bin/lxdm(-bi‐
477            nary)?,    /usr/X11R6/bin/[xgkw]dm,     /usr/bin/razor-lightdm-.*,
478            /usr/bin/sddm,  /usr/bin/slim, /usr/bin/gpe-dm, /opt/kde3/bin/kdm,
479            /usr/sbin/mdm-binary,                       /usr/bin/sddm-greeter,
480            /etc/rc.d/init.d/x11-common,      /usr/libexec/gdm-runtime-config,
481            /usr/libexec/gdm-disable-wayland
482
483
484       xdm_home_t
485
486       - Set files with the xdm_home_t type, if you want to store xdm files in
487       the users home directory.
488
489
490       Paths:
491            /root/.dmrc.*,  /root/.wayland-errors.*, /root/.xsession-errors.*,
492            /home/[^/]+/.dmrc.*,                 /home/[^/]+/.cache/gdm(/.*)?,
493            /home/[^/]+/.wayland-errors.*,     /home/[^/]+/.xsession-errors.*,
494            /home/[^/]+/.local/share/xorg(/.*)?
495
496
497       xdm_lock_t
498
499       - Set files with the xdm_lock_t type, if you want to treat the files as
500       xdm lock data, stored under the /var/lock directory
501
502
503
504       xdm_log_t
505
506       -  Set  files with the xdm_log_t type, if you want to treat the data as
507       xdm log data, usually stored under the /var/log directory.
508
509
510       Paths:
511            /var/log/[mkwx]dm.log.*, /var/log/mdm(/.*)?,  /var/log/lxdm.log.*,
512            /var/log/slim.log.*
513
514
515       xdm_rw_etc_t
516
517       -  Set  files  with  the xdm_rw_etc_t type, if you want to store xdm rw
518       files in the /etc directories.
519
520
521       Paths:
522            /etc/X11/wdm(/.*)?, /etc/opt/VirtualGL(/.*)?
523
524
525       xdm_spool_t
526
527       - Set files with the xdm_spool_t type, if you want  to  store  the  xdm
528       files under the /var/spool directory.
529
530
531
532       xdm_tmpfs_t
533
534       -  Set  files with the xdm_tmpfs_t type, if you want to store xdm files
535       on a tmpfs file system.
536
537
538
539       xdm_unconfined_exec_t
540
541       - Set files with the xdm_unconfined_exec_t type, if you want to transi‐
542       tion an executable to the xdm_unconfined_t domain.
543
544
545       Paths:
546            /etc/[mg]dm/Init(/.*)?,               /etc/[mg]dm/PostLogin(/.*)?,
547            /etc/[mg]dm/PreSession(/.*)?, /etc/[mg]dm/PostSession(/.*)?
548
549
550       xdm_unit_file_t
551
552       - Set files with the xdm_unit_file_t type, if you  want  to  treat  the
553       files as xdm unit content.
554
555
556
557       xdm_var_lib_t
558
559       -  Set  files with the xdm_var_lib_t type, if you want to store the xdm
560       files under the /var/lib directory.
561
562
563       Paths:
564            /var/lib/[mxkwg]dm(/.*)?,                 /var/cache/[mg]dm(/.*)?,
565            /var/lib/gdm(3)?(/.*)?,  /var/lib/lxdm(/.*)?, /var/lib/sddm(/.*)?,
566            /var/lib/lightdm(/.*)?,                  /var/cache/lightdm(/.*)?,
567            /var/lib/lightdm-data(/.*)?
568
569
570       xdm_var_run_t
571
572       -  Set  files with the xdm_var_run_t type, if you want to store the xdm
573       files under the /run or /var/run directory.
574
575
576       Paths:
577            /etc/kde[34]?/kdm/backgroundrc,            /var/run/[kgm]dm(/.*)?,
578            /var/run/gdm(3)?.pid,                      /var/run/gdm(3)?(/.*)?,
579            /usr/lib/qt-.*/etc/settings(/.*)?,                /var/run/slim.*,
580            /var/run/lxdm(/.*)?,   /var/run/sddm(/.*)?,  /var/run/xauth(/.*)?,
581            /var/run/xdmctl(/.*)?,    /var/run/lightdm(/.*)?,    /var/run/sys‐
582            temd/multi-session-x(/.*)?,  /var/run/xdm.pid,  /var/run/lxdm.pid,
583            /var/run/lxdm.auth, /var/run/gdm_socket
584
585
586       Note: File context can be temporarily modified with the chcon  command.
587       If  you want to permanently change the file context you need to use the
588       semanage fcontext command.  This will modify the SELinux labeling data‐
589       base.  You will need to use restorecon to apply the labels.
590
591

COMMANDS

593       semanage  fcontext  can also be used to manipulate default file context
594       mappings.
595
596       semanage permissive can also be used to manipulate  whether  or  not  a
597       process type is permissive.
598
599       semanage  module can also be used to enable/disable/install/remove pol‐
600       icy modules.
601
602       semanage port can also be used to manipulate the port definitions
603
604       semanage boolean can also be used to manipulate the booleans
605
606
607       system-config-selinux is a GUI tool available to customize SELinux pol‐
608       icy settings.
609
610

AUTHOR

612       This manual page was auto-generated using sepolicy manpage .
613
614

SEE ALSO

616       selinux(8),  xdm(8), semanage(8), restorecon(8), chcon(1), sepolicy(8),
617       setsebool(8), xdm_unconfined_selinux(8), xdm_unconfined_selinux(8)
618
619
620
621xdm                                23-10-20                     xdm_selinux(8)
Impressum