Bug 725130 - SELinux is preventing /usr/sbin/wpa_supplicant from 'read' accesses on the netlink_socket Unknown.
Summary: SELinux is preventing /usr/sbin/wpa_supplicant from 'read' accesses on the ne...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: rawhide
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:faddbf08792...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-07-23 00:45 UTC by Ryan Rix
Modified: 2011-11-21 16:59 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-11-21 16:59:56 UTC
Type: ---


Attachments (Terms of Use)

Description Ryan Rix 2011-07-23 00:45:53 UTC
SELinux is preventing /usr/sbin/wpa_supplicant from 'read' accesses on the netlink_socket Unknown.

*****  Plugin catchall (100. confidence) suggests  ***************************

If you believe that wpa_supplicant should be allowed read access on the Unknown netlink_socket by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
Do
allow this access for now by executing:
# grep wpa_supplicant /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:NetworkManager_t:s0
Target Context                system_u:system_r:NetworkManager_t:s0
Target Objects                Unknown [ netlink_socket ]
Source                        wpa_supplicant
Source Path                   /usr/sbin/wpa_supplicant
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           wpa_supplicant-0.7.3-6.fc15
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.16-34.fc15
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Host Name                     (removed)
Platform                      Linux (removed) 2.6.38.8-35.fc15.x86_64 #1 SMP Wed
                              Jul 6 13:58:54 UTC 2011 x86_64 x86_64
Alert Count                   4
First Seen                    Fri 22 Jul 2011 05:42:42 PM MST
Last Seen                     Fri 22 Jul 2011 05:43:42 PM MST
Local ID                      dface9b1-791c-45cd-aaca-7d9228e5bcd0

Raw Audit Messages
type=AVC msg=audit(1311381822.587:216): avc:  denied  { read } for  pid=2310 comm="wpa_supplicant" scontext=system_u:system_r:NetworkManager_t:s0 tcontext=system_u:system_r:NetworkManager_t:s0 tclass=netlink_socket


type=SYSCALL msg=audit(1311381822.587:216): arch=x86_64 syscall=recvmsg success=yes exit=ENAMETOOLONG a0=5 a1=7fffcba264d0 a2=0 a3=0 items=0 ppid=1 pid=2310 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=wpa_supplicant exe=/usr/sbin/wpa_supplicant subj=system_u:system_r:NetworkManager_t:s0 key=(null)

Hash: wpa_supplicant,NetworkManager_t,NetworkManager_t,netlink_socket,read

audit2allow

#============= NetworkManager_t ==============
allow NetworkManager_t self:netlink_socket read;

audit2allow -R

#============= NetworkManager_t ==============
allow NetworkManager_t self:netlink_socket read;

Comment 1 Miroslav Grepl 2011-07-25 13:49:24 UTC
Could you try to execute

yum reinstall selinux-policy-targeted

and make sure nothing complains on reinstall.

Comment 2 Ryan Rix 2011-07-25 23:57:13 UTC
Uhm, I don't know what would cause this but: 

No Match for argument: selinux-policy-targeted
Package(s) selinux-policy-targeted available, but not installed.
Nothing to do

So... my system's rpmdb probably got damaged at some point, or something, and thus stuff like that isn't getting updates. 

When I installed the package, I got this output:

Running Transaction
  Installing : selinux-policy-targeted-3.9.16-34.fc15.noarch                                  1/1 
libsepol.scope_copy_callback: passenger: Duplicate declaration in module: type/attribute passenger_tmp_t (No such file or directory).
libsemanage.semanage_link_sandbox: Link packages failed (No such file or directory).
semodule:  Failed!

Installed:
  selinux-policy-targeted.noarch 0:3.9.16-34.fc15

Comment 3 Miroslav Grepl 2011-07-26 06:06:49 UTC
ok, could you just try to execute

# yum update selinux-policy-targeted --enablerepo=updates-testing

Comment 4 Ryan Rix 2011-07-26 13:07:12 UTC
That appeared to have installed cleanly:


Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Updating   : selinux-policy-3.9.16-35.fc15.noarch                       1/4 
  Updating   : selinux-policy-targeted-3.9.16-35.fc15.noarch              2/4 
*************************************************************************
  Cleanup    : selinux-policy-targeted-3.9.16-34.fc15.noarch              3/4 
  Cleanup    : selinux-policy-3.9.16-34.fc15.noarch                       4/4 

Updated:
  selinux-policy-targeted.noarch 0:3.9.16-35.fc15                             

Dependency Updated:
  selinux-policy.noarch 0:3.9.16-35.fc15                                      

Complete!


I'll schedule a relabel and reboot momentarily

Comment 5 Daniel Walsh 2011-11-21 16:59:56 UTC
I take it everything is fine now.


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