1postfix_smtp_selinux(8) SELinux Policy postfix_smtp postfix_smtp_selinux(8)
2
3
4
6 postfix_smtp_selinux - Security Enhanced Linux Policy for the post‐
7 fix_smtp processes
8
10 Security-Enhanced Linux secures the postfix_smtp processes via flexible
11 mandatory access control.
12
13 The postfix_smtp processes execute with the postfix_smtp_t SELinux
14 type. You can check if you have these processes running by executing
15 the ps command with the -Z qualifier.
16
17 For example:
18
19 ps -eZ | grep postfix_smtp_t
20
21
22
24 The postfix_smtp_t SELinux type can be entered via the post‐
25 fix_smtp_exec_t file type.
26
27 The default entrypoint paths for the postfix_smtp_t domain are the fol‐
28 lowing:
29
30 /usr/libexec/postfix/lmtp, /usr/libexec/postfix/smtp,
31 /usr/libexec/postfix/scache
32
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 postfix_smtp policy is very flexible allowing users to setup their
41 postfix_smtp processes in as secure a method as possible.
42
43 The following process types are defined for postfix_smtp:
44
45 postfix_smtpd_t, postfix_smtp_t
46
47 Note: semanage permissive -a postfix_smtp_t can be used to make the
48 process type postfix_smtp_t permissive. SELinux does not deny access to
49 permissive process types, but the AVC (SELinux denials) messages are
50 still generated.
51
52
54 SELinux policy is customizable based on least access required. post‐
55 fix_smtp policy is extremely flexible and has several booleans that
56 allow you to manipulate the policy and run postfix_smtp with the tight‐
57 est access possible.
58
59
60
61 If you want to allow all domains to use other domains file descriptors,
62 you must turn on the allow_domain_fd_use boolean. Enabled by default.
63
64 setsebool -P allow_domain_fd_use 1
65
66
67
68 If you want to allow confined applications to run with kerberos, you
69 must turn on the allow_kerberos boolean. Enabled by default.
70
71 setsebool -P allow_kerberos 1
72
73
74
75 If you want to allow sysadm to debug or ptrace all processes, you must
76 turn on the allow_ptrace boolean. Disabled by default.
77
78 setsebool -P allow_ptrace 1
79
80
81
82 If you want to allow system to run with NIS, you must turn on the
83 allow_ypbind boolean. Disabled by default.
84
85 setsebool -P allow_ypbind 1
86
87
88
89 If you want to allow all domains to have the kernel load modules, you
90 must turn on the domain_kernel_load_modules boolean. Disabled by
91 default.
92
93 setsebool -P domain_kernel_load_modules 1
94
95
96
97 If you want to allow all domains to execute in fips_mode, you must turn
98 on the fips_mode boolean. Enabled by default.
99
100 setsebool -P fips_mode 1
101
102
103
104 If you want to enable reading of urandom for all domains, you must turn
105 on the global_ssp boolean. Disabled by default.
106
107 setsebool -P global_ssp 1
108
109
110
111 If you want to allow confined applications to use nscd shared memory,
112 you must turn on the nscd_use_shm boolean. Enabled by default.
113
114 setsebool -P nscd_use_shm 1
115
116
117
119 The SELinux process type postfix_smtp_t can manage files labeled with
120 the following file types. The paths listed are the default paths for
121 these file types. Note the processes UID still need to have DAC per‐
122 missions.
123
124 anon_inodefs_t
125
126
127 initrc_tmp_t
128
129
130 mnt_t
131
132 /mnt(/[^/]*)
133 /mnt(/[^/]*)?
134 /rhev(/[^/]*)?
135 /media(/[^/]*)
136 /media(/[^/]*)?
137 /etc/rhgb(/.*)?
138 /media/.hal-.*
139 /net
140 /afs
141 /rhev
142 /misc
143
144 postfix_prng_t
145
146 /etc/postfix/prng_exch
147
148 postfix_smtp_tmp_t
149
150
151 postfix_spool_maildrop_t
152
153 /var/spool/postfix/defer(/.*)?
154 /var/spool/postfix/deferred(/.*)?
155 /var/spool/postfix/maildrop(/.*)?
156
157 postfix_spool_t
158
159 /var/spool/postfix.*
160
161 postfix_var_run_t
162
163 /var/spool/postfix/pid/.*
164
165 tmp_t
166
167 /tmp
168 /usr/tmp
169 /var/tmp
170 /tmp-inst
171 /var/tmp-inst
172 /var/tmp/vi.recover
173
174
176 SELinux requires files to have an extended attribute to define the file
177 type.
178
179 You can see the context of a file using the -Z option to ls
180
181 Policy governs the access confined processes have to these files.
182 SELinux postfix_smtp policy is very flexible allowing users to setup
183 their postfix_smtp processes in as secure a method as possible.
184
185 STANDARD FILE CONTEXT
186
187 SELinux defines the file context types for the postfix_smtp, if you
188 wanted to store files with these types in a diffent paths, you need to
189 execute the semanage command to sepecify alternate labeling and then
190 use restorecon to put the labels on disk.
191
192 semanage fcontext -a -t postfix_smtpd_tmp_t '/srv/mypostfix_smtp_con‐
193 tent(/.*)?'
194 restorecon -R -v /srv/mypostfix_smtp_content
195
196 Note: SELinux often uses regular expressions to specify labels that
197 match multiple files.
198
199 The following file types are defined for postfix_smtp:
200
201
202
203 postfix_smtp_exec_t
204
205 - Set files with the postfix_smtp_exec_t type, if you want to transi‐
206 tion an executable to the postfix_smtp_t domain.
207
208
209 Paths:
210 /usr/libexec/postfix/lmtp, /usr/libexec/postfix/smtp,
211 /usr/libexec/postfix/scache
212
213
214 postfix_smtp_tmp_t
215
216 - Set files with the postfix_smtp_tmp_t type, if you want to store
217 postfix smtp temporary files in the /tmp directories.
218
219
220
221 postfix_smtpd_exec_t
222
223 - Set files with the postfix_smtpd_exec_t type, if you want to transi‐
224 tion an executable to the postfix_smtpd_t domain.
225
226
227
228 postfix_smtpd_tmp_t
229
230 - Set files with the postfix_smtpd_tmp_t type, if you want to store
231 postfix smtpd temporary files in the /tmp directories.
232
233
234
235 Note: File context can be temporarily modified with the chcon command.
236 If you want to permanently change the file context you need to use the
237 semanage fcontext command. This will modify the SELinux labeling data‐
238 base. You will need to use restorecon to apply the labels.
239
240
242 semanage fcontext can also be used to manipulate default file context
243 mappings.
244
245 semanage permissive can also be used to manipulate whether or not a
246 process type is permissive.
247
248 semanage module can also be used to enable/disable/install/remove pol‐
249 icy modules.
250
251 semanage boolean can also be used to manipulate the booleans
252
253
254 system-config-selinux is a GUI tool available to customize SELinux pol‐
255 icy settings.
256
257
259 This manual page was auto-generated using sepolicy manpage .
260
261
263 selinux(8), postfix_smtp(8), semanage(8), restorecon(8), chcon(1) ,
264 setsebool(8)
265
266
267
268postfix_smtp 15-06-03 postfix_smtp_selinux(8)