1crond_selinux(8) SELinux Policy crond crond_selinux(8)
2
3
4
6 crond_selinux - Security Enhanced Linux Policy for the crond processes
7
9 Security-Enhanced Linux secures the crond processes via flexible manda‐
10 tory access control.
11
12 The crond processes execute with the crond_t SELinux type. You can
13 check if you have these processes running by executing the ps command
14 with the -Z qualifier.
15
16 For example:
17
18 ps -eZ | grep crond_t
19
20
21
23 The crond_t SELinux type can be entered via the crond_exec_t file type.
24
25 The default entrypoint paths for the crond_t domain are the following:
26
27 /usr/sbin/cron(d)?, /usr/sbin/atd, /usr/sbin/fcron, /usr/libexec/fcron
28
30 SELinux defines process types (domains) for each process running on the
31 system
32
33 You can see the context of a process using the -Z option to ps
34
35 Policy governs the access confined processes have to files. SELinux
36 crond policy is very flexible allowing users to setup their crond pro‐
37 cesses in as secure a method as possible.
38
39 The following process types are defined for crond:
40
41 crond_t
42
43 Note: semanage permissive -a crond_t can be used to make the process
44 type crond_t permissive. SELinux does not deny access to permissive
45 process types, but the AVC (SELinux denials) messages are still gener‐
46 ated.
47
48
50 SELinux policy is customizable based on least access required. crond
51 policy is extremely flexible and has several booleans that allow you to
52 manipulate the policy and run crond with the tightest access possible.
53
54
55
56 If you want to determine whether crond can execute jobs in the user
57 domain as opposed to the the generic cronjob domain, you must turn on
58 the cron_userdomain_transition boolean. Disabled by default.
59
60 setsebool -P cron_userdomain_transition 1
61
62
63
64 If you want to allow users to resolve user passwd entries directly from
65 ldap rather then using a sssd server, you must turn on the authlo‐
66 gin_nsswitch_use_ldap boolean. Disabled by default.
67
68 setsebool -P authlogin_nsswitch_use_ldap 1
69
70
71
72 If you want to deny user domains applications to map a memory region as
73 both executable and writable, this is dangerous and the executable
74 should be reported in bugzilla, you must turn on the deny_execmem bool‐
75 ean. Enabled by default.
76
77 setsebool -P deny_execmem 1
78
79
80
81 If you want to enable extra rules in the cron domain to support fcron,
82 you must turn on the fcron_crond boolean. Disabled by default.
83
84 setsebool -P fcron_crond 1
85
86
87
88 If you want to allow all domains to execute in fips_mode, you must turn
89 on the fips_mode boolean. Enabled by default.
90
91 setsebool -P fips_mode 1
92
93
94
95 If you want to allow confined applications to run with kerberos, you
96 must turn on the kerberos_enabled boolean. Enabled by default.
97
98 setsebool -P kerberos_enabled 1
99
100
101
102 If you want to control the ability to mmap a low area of the address
103 space, as configured by /proc/sys/vm/mmap_min_addr, you must turn on
104 the mmap_low_allowed boolean. Disabled by default.
105
106 setsebool -P mmap_low_allowed 1
107
108
109
110 If you want to allow system to run with NIS, you must turn on the
111 nis_enabled boolean. Disabled by default.
112
113 setsebool -P nis_enabled 1
114
115
116
117 If you want to allow confined applications to use nscd shared memory,
118 you must turn on the nscd_use_shm boolean. Disabled by default.
119
120 setsebool -P nscd_use_shm 1
121
122
123
124 If you want to enable polyinstantiated directory support, you must turn
125 on the polyinstantiation_enabled boolean. Disabled by default.
126
127 setsebool -P polyinstantiation_enabled 1
128
129
130
131 If you want to disable kernel module loading, you must turn on the
132 secure_mode_insmod boolean. Enabled by default.
133
134 setsebool -P secure_mode_insmod 1
135
136
137
138 If you want to allow unconfined executables to make their heap memory
139 executable. Doing this is a really bad idea. Probably indicates a
140 badly coded executable, but could indicate an attack. This executable
141 should be reported in bugzilla, you must turn on the selin‐
142 uxuser_execheap boolean. Disabled by default.
143
144 setsebool -P selinuxuser_execheap 1
145
146
147
148 If you want to allow unconfined executables to make their stack exe‐
149 cutable. This should never, ever be necessary. Probably indicates a
150 badly coded executable, but could indicate an attack. This executable
151 should be reported in bugzilla, you must turn on the selinuxuser_exec‐
152 stack boolean. Enabled by default.
153
154 setsebool -P selinuxuser_execstack 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
173 The SELinux process type crond_t can manage files labeled with the fol‐
174 lowing file types. The paths listed are the default paths for these
175 file types. Note the processes UID still need to have DAC permissions.
176
177 file_type
178
179 all files on the system
180
181
183 SELinux requires files to have an extended attribute to define the file
184 type.
185
186 You can see the context of a file using the -Z option to ls
187
188 Policy governs the access confined processes have to these files.
189 SELinux crond policy is very flexible allowing users to setup their
190 crond processes in as secure a method as possible.
191
192 STANDARD FILE CONTEXT
193
194 SELinux defines the file context types for the crond, if you wanted to
195 store files with these types in a diffent paths, you need to execute
196 the semanage command to sepecify alternate labeling and then use
197 restorecon to put the labels on disk.
198
199 semanage fcontext -a -t crond_var_run_t '/srv/mycrond_content(/.*)?'
200 restorecon -R -v /srv/mycrond_content
201
202 Note: SELinux often uses regular expressions to specify labels that
203 match multiple files.
204
205 The following file types are defined for crond:
206
207
208
209 crond_exec_t
210
211 - Set files with the crond_exec_t type, if you want to transition an
212 executable to the crond_t domain.
213
214
215 Paths:
216 /usr/sbin/cron(d)?, /usr/sbin/atd, /usr/sbin/fcron,
217 /usr/libexec/fcron
218
219
220 crond_initrc_exec_t
221
222 - Set files with the crond_initrc_exec_t type, if you want to transi‐
223 tion an executable to the crond_initrc_t domain.
224
225
226
227 crond_tmp_t
228
229 - Set files with the crond_tmp_t type, if you want to store crond tem‐
230 porary files in the /tmp directories.
231
232
233
234 crond_unit_file_t
235
236 - Set files with the crond_unit_file_t type, if you want to treat the
237 files as crond unit content.
238
239
240 Paths:
241 /usr/lib/systemd/system/atd.*, /usr/lib/systemd/system/crond.*
242
243
244 crond_var_run_t
245
246 - Set files with the crond_var_run_t type, if you want to store the
247 crond files under the /run or /var/run directory.
248
249
250 Paths:
251 /var/run/.*cron.*, /var/run/crond?.pid, /var/run/crond?.reboot,
252 /var/run/atd.pid, /var/run/fcron.pid, /var/run/fcron.fifo,
253 /var/run/anacron.pid
254
255
256 Note: File context can be temporarily modified with the chcon command.
257 If you want to permanently change the file context you need to use the
258 semanage fcontext command. This will modify the SELinux labeling data‐
259 base. You will need to use restorecon to apply the labels.
260
261
263 semanage fcontext can also be used to manipulate default file context
264 mappings.
265
266 semanage permissive can also be used to manipulate whether or not a
267 process type is permissive.
268
269 semanage module can also be used to enable/disable/install/remove pol‐
270 icy modules.
271
272 semanage boolean can also be used to manipulate the booleans
273
274
275 system-config-selinux is a GUI tool available to customize SELinux pol‐
276 icy settings.
277
278
280 This manual page was auto-generated using sepolicy manpage .
281
282
284 selinux(8), crond(8), semanage(8), restorecon(8), chcon(1), sepol‐
285 icy(8), setsebool(8)
286
287
288
289crond 19-06-18 crond_selinux(8)