1dnsmasq_selinux(8) SELinux Policy dnsmasq dnsmasq_selinux(8)
2
3
4
6 dnsmasq_selinux - Security Enhanced Linux Policy for the dnsmasq pro‐
7 cesses
8
10 Security-Enhanced Linux secures the dnsmasq processes via flexible
11 mandatory access control.
12
13 The dnsmasq processes execute with the dnsmasq_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 dnsmasq_t
20
21
22
24 The dnsmasq_t SELinux type can be entered via the dnsmasq_exec_t file
25 type.
26
27 The default entrypoint paths for the dnsmasq_t domain are the follow‐
28 ing:
29
30 /usr/sbin/dnsmasq
31
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 dnsmasq policy is very flexible allowing users to setup their dnsmasq
40 processes in as secure a method as possible.
41
42 The following process types are defined for dnsmasq:
43
44 dnsmasq_t
45
46 Note: semanage permissive -a dnsmasq_t can be used to make the process
47 type dnsmasq_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
53 SELinux policy is customizable based on least access required. dnsmasq
54 policy is extremely flexible and has several booleans that allow you to
55 manipulate the policy and run dnsmasq with the tightest access possi‐
56 ble.
57
58
59
60 If you want to allow the dnsmasq to creating and using netlink_sockets,
61 you must turn on the dnsmasq_use_ipset boolean. Disabled by default.
62
63 setsebool -P dnsmasq_use_ipset 1
64
65
66
67 If you want to allow all domains to execute in fips_mode, you must turn
68 on the fips_mode boolean. Enabled by default.
69
70 setsebool -P fips_mode 1
71
72
73
75 The SELinux process type dnsmasq_t can manage files labeled with the
76 following file types. The paths listed are the default paths for these
77 file types. Note the processes UID still need to have DAC permissions.
78
79 NetworkManager_var_lib_t
80
81 /var/lib/wicd(/.*)?
82 /var/lib/NetworkManager(/.*)?
83 /etc/dhcp/wired-settings.conf
84 /etc/wicd/wired-settings.conf
85 /etc/dhcp/manager-settings.conf
86 /etc/wicd/manager-settings.conf
87 /etc/dhcp/wireless-settings.conf
88 /etc/wicd/wireless-settings.conf
89
90 NetworkManager_var_run_t
91
92 /var/run/teamd(/.*)?
93 /var/run/nm-xl2tpd.conf.*
94 /var/run/nm-dhclient.*
95 /var/run/NetworkManager(/.*)?
96 /var/run/wpa_supplicant(/.*)?
97 /var/run/wicd.pid
98 /var/run/NetworkManager.pid
99 /var/run/nm-dns-dnsmasq.conf
100 /var/run/wpa_supplicant-global
101
102 cluster_conf_t
103
104 /etc/cluster(/.*)?
105
106 cluster_var_lib_t
107
108 /var/lib/pcsd(/.*)?
109 /var/lib/cluster(/.*)?
110 /var/lib/openais(/.*)?
111 /var/lib/pengine(/.*)?
112 /var/lib/corosync(/.*)?
113 /usr/lib/heartbeat(/.*)?
114 /var/lib/heartbeat(/.*)?
115 /var/lib/pacemaker(/.*)?
116
117 cluster_var_run_t
118
119 /var/run/crm(/.*)?
120 /var/run/cman_.*
121 /var/run/rsctmp(/.*)?
122 /var/run/aisexec.*
123 /var/run/heartbeat(/.*)?
124 /var/run/corosync-qnetd(/.*)?
125 /var/run/corosync-qdevice(/.*)?
126 /var/run/corosync.pid
127 /var/run/cpglockd.pid
128 /var/run/rgmanager.pid
129 /var/run/cluster/rgmanager.sk
130
131 crond_var_run_t
132
133 /var/run/.*cron.*
134 /var/run/crond?.pid
135 /var/run/crond?.reboot
136 /var/run/atd.pid
137 /var/run/fcron.pid
138 /var/run/fcron.fifo
139 /var/run/anacron.pid
140
141 dnsmasq_lease_t
142
143 /var/lib/dnsmasq(/.*)?
144 /var/lib/misc/dnsmasq.leases
145
146 dnsmasq_var_run_t
147
148 /var/run/dnsmasq.*
149 /var/run/libvirt/network(/.*)?
150
151 mnt_t
152
153 /mnt(/[^/]*)?
154 /mnt(/[^/]*)?
155 /rhev(/[^/]*)?
156 /rhev/[^/]*/.*
157 /media(/[^/]*)?
158 /media(/[^/]*)?
159 /media/.hal-.*
160 /var/run/media(/[^/]*)?
161 /afs
162 /net
163 /misc
164 /rhev
165
166 neutron_var_lib_t
167
168 /var/lib/neutron(/.*)?
169 /var/lib/quantum(/.*)?
170
171 root_t
172
173 /sysroot/ostree/deploy/.*-atomic/deploy(/.*)?
174 /
175 /initrd
176
177
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 dnsmasq policy is very flexible allowing users to setup their
186 dnsmasq processes in as secure a method as possible.
187
188 STANDARD FILE CONTEXT
189
190 SELinux defines the file context types for the dnsmasq, if you wanted
191 to 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 dnsmasq_tmp_t '/srv/mydnsmasq_content(/.*)?'
196 restorecon -R -v /srv/mydnsmasq_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 dnsmasq:
202
203
204
205 dnsmasq_etc_t
206
207 - Set files with the dnsmasq_etc_t type, if you want to store dnsmasq
208 files in the /etc directories.
209
210
211 Paths:
212 /etc/dnsmasq.d(/.*)?, /etc/dnsmasq.conf
213
214
215 dnsmasq_exec_t
216
217 - Set files with the dnsmasq_exec_t type, if you want to transition an
218 executable to the dnsmasq_t domain.
219
220
221
222 dnsmasq_initrc_exec_t
223
224 - Set files with the dnsmasq_initrc_exec_t type, if you want to transi‐
225 tion an executable to the dnsmasq_initrc_t domain.
226
227
228
229 dnsmasq_lease_t
230
231 - Set files with the dnsmasq_lease_t type, if you want to treat the
232 files as dnsmasq lease data.
233
234
235 Paths:
236 /var/lib/dnsmasq(/.*)?, /var/lib/misc/dnsmasq.leases
237
238
239 dnsmasq_tmp_t
240
241 - Set files with the dnsmasq_tmp_t type, if you want to store dnsmasq
242 temporary files in the /tmp directories.
243
244
245
246 dnsmasq_unit_file_t
247
248 - Set files with the dnsmasq_unit_file_t type, if you want to treat the
249 files as dnsmasq unit content.
250
251
252
253 dnsmasq_var_log_t
254
255 - Set files with the dnsmasq_var_log_t type, if you want to treat the
256 data as dnsmasq var log data, usually stored under the /var/log direc‐
257 tory.
258
259
260
261 dnsmasq_var_run_t
262
263 - Set files with the dnsmasq_var_run_t type, if you want to store the
264 dnsmasq files under the /run or /var/run directory.
265
266
267 Paths:
268 /var/run/dnsmasq.*, /var/run/libvirt/network(/.*)?
269
270
271 Note: File context can be temporarily modified with the chcon command.
272 If you want to permanently change the file context you need to use the
273 semanage fcontext command. This will modify the SELinux labeling data‐
274 base. You will need to use restorecon to apply the labels.
275
276
278 semanage fcontext can also be used to manipulate default file context
279 mappings.
280
281 semanage permissive can also be used to manipulate whether or not a
282 process type is permissive.
283
284 semanage module can also be used to enable/disable/install/remove pol‐
285 icy modules.
286
287 semanage boolean can also be used to manipulate the booleans
288
289
290 system-config-selinux is a GUI tool available to customize SELinux pol‐
291 icy settings.
292
293
295 This manual page was auto-generated using sepolicy manpage .
296
297
299 selinux(8), dnsmasq(8), semanage(8), restorecon(8), chcon(1), sepol‐
300 icy(8), setsebool(8)
301
302
303
304dnsmasq 21-03-26 dnsmasq_selinux(8)