1insmod_selinux(8)            SELinux Policy insmod           insmod_selinux(8)
2
3
4

NAME

6       insmod_selinux  -  Security  Enhanced  Linux Policy for the insmod pro‐
7       cesses
8

DESCRIPTION

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

ENTRYPOINTS

24       The  insmod_t  SELinux  type  can be entered via the insmod_exec_t file
25       type.
26
27       The default entrypoint paths for the insmod_t domain are the following:
28
29       /sbin/rmmod.*,  /sbin/insmod.*,  /sbin/modprobe.*,   /usr/sbin/rmmod.*,
30       /usr/sbin/insmod.*, /usr/sbin/modprobe.*, /bin/kmod, /usr/bin/kmod
31

PROCESS TYPES

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

BOOLEANS

53       SELinux  policy is customizable based on least access required.  insmod
54       policy is extremely flexible and has several booleans that allow you to
55       manipulate the policy and run insmod with the tightest access possible.
56
57
58
59       If you want to allow users to resolve user passwd entries directly from
60       ldap rather then using a sssd server, you  must  turn  on  the  authlo‐
61       gin_nsswitch_use_ldap boolean. Disabled by default.
62
63       setsebool -P authlogin_nsswitch_use_ldap 1
64
65
66
67       If you want to deny user domains applications to map a memory region as
68       both executable and writable, this  is  dangerous  and  the  executable
69       should be reported in bugzilla, you must turn on the deny_execmem bool‐
70       ean. Enabled by default.
71
72       setsebool -P deny_execmem 1
73
74
75
76       If you want to deny any process from ptracing or  debugging  any  other
77       processes,  you  must  turn  on  the  deny_ptrace  boolean.  Enabled by
78       default.
79
80       setsebool -P deny_ptrace 1
81
82
83
84       If you want to allow any process  to  mmap  any  file  on  system  with
85       attribute  file_type,  you must turn on the domain_can_mmap_files bool‐
86       ean. Enabled by default.
87
88       setsebool -P domain_can_mmap_files 1
89
90
91
92       If you want to allow all domains write to kmsg_device, while kernel  is
93       executed  with  systemd.log_target=kmsg parameter, you must turn on the
94       domain_can_write_kmsg boolean. Disabled by default.
95
96       setsebool -P domain_can_write_kmsg 1
97
98
99
100       If you want to allow all domains to use other domains file descriptors,
101       you must turn on the domain_fd_use boolean. Enabled by default.
102
103       setsebool -P domain_fd_use 1
104
105
106
107       If  you  want to allow all domains to have the kernel load modules, you
108       must  turn  on  the  domain_kernel_load_modules  boolean.  Disabled  by
109       default.
110
111       setsebool -P domain_kernel_load_modules 1
112
113
114
115       If you want to allow all domains to execute in fips_mode, you must turn
116       on the fips_mode boolean. Enabled by default.
117
118       setsebool -P fips_mode 1
119
120
121
122       If you want to enable reading of urandom for all domains, you must turn
123       on the global_ssp boolean. Disabled by default.
124
125       setsebool -P global_ssp 1
126
127
128
129       If  you  want  to allow confined applications to run with kerberos, you
130       must turn on the kerberos_enabled boolean. Enabled by default.
131
132       setsebool -P kerberos_enabled 1
133
134
135
136       If you want to control the ability to mmap a low area  of  the  address
137       space,  as  configured  by /proc/sys/vm/mmap_min_addr, you must turn on
138       the mmap_low_allowed boolean. Disabled by default.
139
140       setsebool -P mmap_low_allowed 1
141
142
143
144       If you want to allow system to run with  NIS,  you  must  turn  on  the
145       nis_enabled boolean. Disabled by default.
146
147       setsebool -P nis_enabled 1
148
149
150
151       If  you  want to allow confined applications to use nscd shared memory,
152       you must turn on the nscd_use_shm boolean. Disabled by default.
153
154       setsebool -P nscd_use_shm 1
155
156
157
158       If you want to allow pppd to load kernel modules  for  certain  modems,
159       you must turn on the pppd_can_insmod boolean. Disabled by default.
160
161       setsebool -P pppd_can_insmod 1
162
163
164
165       If  you  want  to  disable  kernel module loading, you must turn on the
166       secure_mode_insmod boolean. Enabled by default.
167
168       setsebool -P secure_mode_insmod 1
169
170
171
172       If you want to boolean to determine whether the system permits  loading
173       policy,  setting enforcing mode, and changing boolean values.  Set this
174       to true and you have to reboot to set it back, you  must  turn  on  the
175       secure_mode_policyload boolean. Enabled by default.
176
177       setsebool -P secure_mode_policyload 1
178
179
180
181       If  you  want to allow unconfined executables to make their heap memory
182       executable.  Doing this is a really  bad  idea.  Probably  indicates  a
183       badly  coded  executable, but could indicate an attack. This executable
184       should  be  reported  in  bugzilla,  you  must  turn  on   the   selin‐
185       uxuser_execheap boolean. Disabled by default.
186
187       setsebool -P selinuxuser_execheap 1
188
189
190
191       If  you  want  to  allow  all  unconfined  executables to use libraries
192       requiring text relocation that are  not  labeled  textrel_shlib_t,  you
193       must turn on the selinuxuser_execmod boolean. Enabled by default.
194
195       setsebool -P selinuxuser_execmod 1
196
197
198
199       If  you  want  to allow unconfined executables to make their stack exe‐
200       cutable.  This should never, ever be necessary.  Probably  indicates  a
201       badly  coded  executable, but could indicate an attack. This executable
202       should be reported in bugzilla, you must turn on the  selinuxuser_exec‐
203       stack boolean. Enabled by default.
204
205       setsebool -P selinuxuser_execstack 1
206
207
208
209       If you want to support X userspace object manager, you must turn on the
210       xserver_object_manager boolean. Enabled by default.
211
212       setsebool -P xserver_object_manager 1
213
214
215

MANAGED FILES

217       The SELinux process type insmod_t can manage  files  labeled  with  the
218       following file types.  The paths listed are the default paths for these
219       file types.  Note the processes UID still need to have DAC permissions.
220
221       file_type
222
223            all files on the system
224
225

FILE CONTEXTS

227       SELinux requires files to have an extended attribute to define the file
228       type.
229
230       You can see the context of a file using the -Z option to ls
231
232       Policy  governs  the  access  confined  processes  have to these files.
233       SELinux insmod policy is very flexible allowing users  to  setup  their
234       insmod processes in as secure a method as possible.
235
236       STANDARD FILE CONTEXT
237
238       SELinux defines the file context types for the insmod, if you wanted to
239       store files with these types in a diffent paths, you  need  to  execute
240       the  semanage  command  to  sepecify  alternate  labeling  and then use
241       restorecon to put the labels on disk.
242
243       semanage fcontext -a -t insmod_var_run_t '/srv/myinsmod_content(/.*)?'
244       restorecon -R -v /srv/myinsmod_content
245
246       Note: SELinux often uses regular expressions  to  specify  labels  that
247       match multiple files.
248
249       The following file types are defined for insmod:
250
251
252
253       insmod_exec_t
254
255       -  Set  files with the insmod_exec_t type, if you want to transition an
256       executable to the insmod_t domain.
257
258
259       Paths:
260            /sbin/rmmod.*,          /sbin/insmod.*,          /sbin/modprobe.*,
261            /usr/sbin/rmmod.*,    /usr/sbin/insmod.*,    /usr/sbin/modprobe.*,
262            /bin/kmod, /usr/bin/kmod
263
264
265       insmod_tmpfs_t
266
267       - Set files with the insmod_tmpfs_t type, if you want to  store  insmod
268       files on a tmpfs file system.
269
270
271
272       insmod_var_run_t
273
274       -  Set  files  with the insmod_var_run_t type, if you want to store the
275       insmod files under the /run or /var/run directory.
276
277
278
279       Note: File context can be temporarily modified with the chcon  command.
280       If  you want to permanently change the file context you need to use the
281       semanage fcontext command.  This will modify the SELinux labeling data‐
282       base.  You will need to use restorecon to apply the labels.
283
284

COMMANDS

286       semanage  fcontext  can also be used to manipulate default file context
287       mappings.
288
289       semanage permissive can also be used to manipulate  whether  or  not  a
290       process type is permissive.
291
292       semanage  module can also be used to enable/disable/install/remove pol‐
293       icy modules.
294
295       semanage boolean can also be used to manipulate the booleans
296
297
298       system-config-selinux is a GUI tool available to customize SELinux pol‐
299       icy settings.
300
301

AUTHOR

303       This manual page was auto-generated using sepolicy manpage .
304
305

SEE ALSO

307       selinux(8),  insmod(8),  semanage(8),  restorecon(8),  chcon(1), sepol‐
308       icy(8) , setsebool(8)
309
310
311
312insmod                             19-04-25                  insmod_selinux(8)
Impressum