Bug 866422 - SELinux is preventing /usr/sbin/dnsmasq from 'search' accesses on the directory /etc/NetworkManager.
SELinux is preventing /usr/sbin/dnsmasq from 'search' accesses on the directo...
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-10-15 06:36 EDT by Michael Scherer
Modified: 2012-12-20 10:05 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-12-20 10:05:40 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
File: type (9 bytes, text/plain)
2012-10-15 06:36 EDT, Michael Scherer
no flags Details
File: hashmarkername (14 bytes, text/plain)
2012-10-15 06:36 EDT, Michael Scherer
no flags Details

  None (edit)
Description Michael Scherer 2012-10-15 06:36:12 EDT
Description of problem:
tried to use a 3g key on a up to date fedora 18. Doesn't seems to appear with regular wifi or wired connexion.
FOr what is worth, here is my NetworkManager.conf :


Since I use dnsmasq as a dns proxy ( to cope with vpn over public wifi with a dns that does redirect on domain not found ), I think this may requires dnsmasq to read some file in the directory, but I do not know why. Things work fine however without the access.

Additional info:
libreport version: 2.0.16
kernel:         3.6.1-1.fc18.x86_64

:SELinux is preventing /usr/sbin/dnsmasq from 'search' accesses on the directory /etc/NetworkManager.
:*****  Plugin catchall (100. confidence) suggests  ***************************
:If vous pensez que dnsmasq devrait être autorisé à accéder search sur NetworkManager directory par défaut.
:Then vous devriez rapporter ceci en tant qu'anomalie.
:Vous pouvez générer un module de stratégie local pour autoriser cet accès.
:autoriser cet accès pour le moment en exécutant :
:# grep dnsmasq /var/log/audit/audit.log | audit2allow -M mypol
:# semodule -i mypol.pp
:Additional Information:
:Source Context                system_u:system_r:dnsmasq_t:s0
:Target Context                system_u:object_r:NetworkManager_etc_t:s0
:Target Objects                /etc/NetworkManager [ dir ]
:Source                        dnsmasq
:Source Path                   /usr/sbin/dnsmasq
:Port                          <Inconnu>
:Host                          (removed)
:Source RPM Packages           dnsmasq-2.59-6.fc18.x86_64
:Target RPM Packages           NetworkManager-
:                              puppet-2.7.18-1.fc18.noarch
:                              initscripts-9.41-2.fc18.x86_64
:                              dhclient-4.2.4-18.P2.fc18.x86_64
:Policy RPM                    selinux-policy-3.11.1-36.fc18.noarch
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Enforcing
:Host Name                     (removed)
:Platform                      Linux (removed) 3.6.1-1.fc18.x86_64 #1 SMP Mon Oct
:                              8 17:19:09 UTC 2012 x86_64 x86_64
:Alert Count                   18
:First Seen                    2012-10-14 19:11:30 CEST
:Last Seen                     2012-10-15 11:51:05 CEST
:Local ID                      5b86e4a9-571d-4e44-b3f6-b909f6313d91
:Raw Audit Messages
:type=AVC msg=audit(1350294665.31:700): avc:  denied  { search } for  pid=5617 comm="dnsmasq" name="NetworkManager" dev="dm-2" ino=2228870 scontext=system_u:system_r:dnsmasq_t:s0 tcontext=system_u:object_r:NetworkManager_etc_t:s0 tclass=dir
:type=SYSCALL msg=audit(1350294665.31:700): arch=x86_64 syscall=openat success=no exit=EACCES a0=ffffffffffffff9c a1=145eb70 a2=90800 a3=0 items=0 ppid=843 pid=5617 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=dnsmasq exe=/usr/sbin/dnsmasq subj=system_u:system_r:dnsmasq_t:s0 key=(null)
:Hash: dnsmasq,dnsmasq_t,NetworkManager_etc_t,dir,search
:#============= dnsmasq_t ==============
:allow dnsmasq_t NetworkManager_etc_t:dir search;
:audit2allow -R
:#============= dnsmasq_t ==============
:allow dnsmasq_t NetworkManager_etc_t:dir search;
Comment 1 Michael Scherer 2012-10-15 06:36:15 EDT
Created attachment 627293 [details]
File: type
Comment 2 Michael Scherer 2012-10-15 06:36:17 EDT
Created attachment 627294 [details]
File: hashmarkername
Comment 3 Miroslav Grepl 2012-10-16 07:37:26 EDT
Fixed in selinux-policy-3.11.1-40.fc18.noarch
Comment 4 Michael Scherer 2012-10-21 05:32:19 EDT
tried to connect to my work VPN, using openvpn and network-manager

Package: (null)
OS Release: Fedora release 18 (Spherical Cow)
Comment 5 Fedora Update System 2012-10-23 16:34:48 EDT
selinux-policy-3.11.1-43.fc18 has been submitted as an update for Fedora 18.
Comment 6 Fedora Update System 2012-10-26 11:37:47 EDT
selinux-policy-3.11.1-46.fc18 has been submitted as an update for Fedora 18.
Comment 7 Fedora Update System 2012-10-26 15:27:15 EDT
Package selinux-policy-3.11.1-46.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.11.1-46.fc18'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).
Comment 8 Fedora Update System 2012-12-20 10:05:43 EST
selinux-policy-3.11.1-46.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.