Bug 684697

Summary: SELinux is preventing /usr/bin/qemu-kvm from 'read' accesses on the chr_file /dev/bus/usb/001/007.
Product: [Fedora] Fedora Reporter: Artur Szymczak <ajes+redhat>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 14CC: bob, dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:6cae0ce20e3f4d547b99706deb246ce639de6a1f428e638df41faef9e3baa193
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-03-14 12:42:34 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Artur Szymczak 2011-03-14 09:12:33 UTC
SELinux is preventing /usr/bin/qemu-kvm from 'read' accesses on the chr_file /dev/bus/usb/001/007.

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

If you believe that qemu-kvm should be allowed read access on the 007 chr_file 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 qemu-kvm /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:svirt_t:s0:c112,c574
Target Context                system_u:object_r:usb_device_t:s0
Target Objects                /dev/bus/usb/001/007 [ chr_file ]
Source                        qemu-kvm
Source Path                   /usr/bin/qemu-kvm
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           qemu-system-x86-0.13.0-1.fc14
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.7-31.fc14
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 2.6.35.11-83.fc14.x86_64
                              #1 SMP Mon Feb 7 07:06:44 UTC 2011 x86_64 x86_64
Alert Count                   4
First Seen                    Mon 14 Mar 2011 10:08:45 AM CET
Last Seen                     Mon 14 Mar 2011 10:09:12 AM CET
Local ID                      671cda50-afca-4e5f-852c-1f54158753ae

Raw Audit Messages
type=AVC msg=audit(1300093752.95:42): avc:  denied  { read } for  pid=2408 comm="qemu-kvm" path="/dev/bus/usb/001/007" dev=devtmpfs ino=43988 scontext=system_u:system_r:svirt_t:s0:c112,c574 tcontext=system_u:object_r:usb_device_t:s0 tclass=chr_file


type=SYSCALL msg=audit(1300093752.95:42): arch=x86_64 syscall=ioctl success=no exit=EACCES a0=14 a1=8038550a a2=212f3b0 a3=1 items=0 ppid=1 pid=2408 auid=4294967295 uid=107 gid=107 euid=107 suid=107 fsuid=107 egid=107 sgid=107 fsgid=107 tty=(none) ses=4294967295 comm=qemu-kvm exe=/usr/bin/qemu-kvm subj=system_u:system_r:svirt_t:s0:c112,c574 key=(null)

Hash: qemu-kvm,svirt_t,usb_device_t,chr_file,read

audit2allow

#============= svirt_t ==============
allow svirt_t usb_device_t:chr_file read;

audit2allow -R

#============= svirt_t ==============
allow svirt_t usb_device_t:chr_file read;

Comment 1 Miroslav Grepl 2011-03-14 12:42:34 UTC

*** This bug has been marked as a duplicate of bug 684695 ***