1lpr_selinux(8)                SELinux Policy lpr                lpr_selinux(8)
2
3
4

NAME

6       lpr_selinux - Security Enhanced Linux Policy for the lpr processes
7

DESCRIPTION

9       Security-Enhanced  Linux  secures the lpr processes via flexible manda‐
10       tory access control.
11
12       The lpr processes execute with the lpr_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 lpr_t
19
20
21

ENTRYPOINTS

23       The lpr_t SELinux type can be entered via the lpr_exec_t file type.
24
25       The default entrypoint paths for the lpr_t domain are the following:
26
27       /usr/bin/lp(.cups)?,    /usr/bin/lpq(.cups)?,     /usr/bin/lpr(.cups)?,
28       /usr/bin/lprm(.cups)?,  /usr/sbin/lpc(.cups)?, /usr/bin/cancel(.cups)?,
29       /usr/bin/lpstat(.cups)?, /opt/gutenprint/s?bin(/.*)?, /usr/local/linux‐
30       printer/bin/l?lpr,          /usr/sbin/accept,         /usr/sbin/lpinfo,
31       /usr/sbin/lpmove, /usr/sbin/lpadmin, /usr/bin/lpoptions
32

PROCESS TYPES

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

BOOLEANS

53       SELinux  policy  is  customizable  based on least access required.  lpr
54       policy is extremely flexible and has several booleans that allow you to
55       manipulate the policy and run lpr with the tightest access possible.
56
57
58
59       If you want to allow all domains to use other domains file descriptors,
60       you must turn on the allow_domain_fd_use boolean. Enabled by default.
61
62       setsebool -P allow_domain_fd_use 1
63
64
65
66       If you want to allow confined applications to run  with  kerberos,  you
67       must turn on the allow_kerberos boolean. Enabled by default.
68
69       setsebool -P allow_kerberos 1
70
71
72
73       If  you want to allow sysadm to debug or ptrace all processes, you must
74       turn on the allow_ptrace boolean. Disabled by default.
75
76       setsebool -P allow_ptrace 1
77
78
79
80       If you want to allow system to run with  NIS,  you  must  turn  on  the
81       allow_ypbind boolean. Disabled by default.
82
83       setsebool -P allow_ypbind 1
84
85
86
87       If  you  want to allow all domains to have the kernel load modules, you
88       must  turn  on  the  domain_kernel_load_modules  boolean.  Disabled  by
89       default.
90
91       setsebool -P domain_kernel_load_modules 1
92
93
94
95       If you want to allow all domains to execute in fips_mode, you must turn
96       on the fips_mode boolean. Enabled by default.
97
98       setsebool -P fips_mode 1
99
100
101
102       If you want to enable reading of urandom for all domains, you must turn
103       on the global_ssp boolean. Disabled by default.
104
105       setsebool -P global_ssp 1
106
107
108
109       If  you  want to allow confined applications to use nscd shared memory,
110       you must turn on the nscd_use_shm boolean. Enabled by default.
111
112       setsebool -P nscd_use_shm 1
113
114
115
116       If you want to use lpd server instead of cups, you  must  turn  on  the
117       use_lpd_server boolean. Disabled by default.
118
119       setsebool -P use_lpd_server 1
120
121
122
123       If  you  want  to  support  NFS  home directories, you must turn on the
124       use_nfs_home_dirs boolean. Disabled by default.
125
126       setsebool -P use_nfs_home_dirs 1
127
128
129
130       If you want to support SAMBA home directories, you  must  turn  on  the
131       use_samba_home_dirs boolean. Disabled by default.
132
133       setsebool -P use_samba_home_dirs 1
134
135
136

MANAGED FILES

138       The  SELinux  process type lpr_t can manage files labeled with the fol‐
139       lowing file types.  The paths listed are the default  paths  for  these
140       file types.  Note the processes UID still need to have DAC permissions.
141
142       initrc_tmp_t
143
144
145       lpr_tmp_t
146
147
148       mnt_t
149
150            /mnt(/[^/]*)
151            /mnt(/[^/]*)?
152            /rhev(/[^/]*)?
153            /media(/[^/]*)
154            /media(/[^/]*)?
155            /etc/rhgb(/.*)?
156            /media/.hal-.*
157            /net
158            /afs
159            /rhev
160            /misc
161
162       print_spool_t
163
164            /var/spool/lpd(/.*)?
165            /var/spool/cups(/.*)?
166            /var/spool/cups-pdf(/.*)?
167
168       tmp_t
169
170            /tmp
171            /usr/tmp
172            /var/tmp
173            /tmp-inst
174            /var/tmp-inst
175            /var/tmp/vi.recover
176
177

FILE CONTEXTS

179       SELinux requires files to have an extended attribute to define the file
180       type.
181
182       You can see the context of a file using the -Z option to ls
183
184       Policy governs the access  confined  processes  have  to  these  files.
185       SELinux  lpr  policy is very flexible allowing users to setup their lpr
186       processes in as secure a method as possible.
187
188       STANDARD FILE CONTEXT
189
190       SELinux defines the file context types for the lpr, if  you  wanted  to
191       store  files  with  these types in a diffent paths, you need to execute
192       the semanage command  to  sepecify  alternate  labeling  and  then  use
193       restorecon to put the labels on disk.
194
195       semanage fcontext -a -t lpr_tmp_t '/srv/mylpr_content(/.*)?'
196       restorecon -R -v /srv/mylpr_content
197
198       Note:  SELinux  often  uses  regular expressions to specify labels that
199       match multiple files.
200
201       The following file types are defined for lpr:
202
203
204
205       lpr_exec_t
206
207       - Set files with the lpr_exec_t type, if you want to transition an exe‐
208       cutable to the lpr_t domain.
209
210
211       Paths:
212            /usr/bin/lp(.cups)?,  /usr/bin/lpq(.cups)?,  /usr/bin/lpr(.cups)?,
213            /usr/bin/lprm(.cups)?,    /usr/sbin/lpc(.cups)?,     /usr/bin/can‐
214            cel(.cups)?, /usr/bin/lpstat(.cups)?, /opt/gutenprint/s?bin(/.*)?,
215            /usr/local/linuxprinter/bin/l?lpr,               /usr/sbin/accept,
216            /usr/sbin/lpinfo,       /usr/sbin/lpmove,       /usr/sbin/lpadmin,
217            /usr/bin/lpoptions
218
219
220       lpr_tmp_t
221
222       - Set files with the lpr_tmp_t type, if you want to store lpr temporary
223       files in the /tmp directories.
224
225
226
227       Note:  File context can be temporarily modified with the chcon command.
228       If you want to permanently change the file context you need to use  the
229       semanage fcontext command.  This will modify the SELinux labeling data‐
230       base.  You will need to use restorecon to apply the labels.
231
232

COMMANDS

234       semanage fcontext can also be used to manipulate default  file  context
235       mappings.
236
237       semanage  permissive  can  also  be used to manipulate whether or not a
238       process type is permissive.
239
240       semanage module can also be used to enable/disable/install/remove  pol‐
241       icy modules.
242
243       semanage boolean can also be used to manipulate the booleans
244
245
246       system-config-selinux is a GUI tool available to customize SELinux pol‐
247       icy settings.
248
249

AUTHOR

251       This manual page was auto-generated using sepolicy manpage .
252
253

SEE ALSO

255       selinux(8), lpr(8), semanage(8), restorecon(8), chcon(1) , setsebool(8)
256
257
258
259lpr                                15-06-03                     lpr_selinux(8)
Impressum