Bug 684618

Summary: SELinux is preventing /usr/sbin/hald from 'getattr' accesses on the blk_file /dev/sda10.
Product: [Fedora] Fedora Reporter: marco
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED INSUFFICIENT_DATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 14CC: dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:721a88efb9209c2421454fe7364ebb7238ca715356bdf739b85e88b473912899
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-04-17 09:02:35 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 marco 2011-03-13 22:00:54 UTC
SELinux is preventing /usr/sbin/hald from 'getattr' accesses on the blk_file /dev/sda10.

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

If you believe that hald should be allowed getattr access on the sda10 blk_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 hald /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:hald_t:s0
Target Context                system_u:object_r:mnt_t:s0
Target Objects                /dev/sda10 [ blk_file ]
Source                        hald
Source Path                   /usr/sbin/hald
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           hal-0.5.14-5.fc14.1
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.7-31.fc14
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
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                   13
First Seen                    Sat 26 Feb 2011 11:22:26 PM CET
Last Seen                     Sun 13 Mar 2011 10:53:46 PM CET
Local ID                      6464516d-c281-456d-b795-98995ea697c6

Raw Audit Messages
type=AVC msg=audit(1300053226.904:3371): avc:  denied  { getattr } for  pid=1740 comm="hald" path="/dev/sda10" dev=devtmpfs ino=5843 scontext=system_u:system_r:hald_t:s0 tcontext=system_u:object_r:mnt_t:s0 tclass=blk_file


type=SYSCALL msg=audit(1300053226.904:3371): arch=x86_64 syscall=stat success=yes exit=0 a0=7fffbc456c50 a1=7fffbc456b80 a2=7fffbc456b80 a3=1999999999999999 items=0 ppid=1 pid=1740 auid=4294967295 uid=68 gid=489 euid=68 suid=68 fsuid=68 egid=489 sgid=489 fsgid=489 tty=(none) ses=4294967295 comm=hald exe=/usr/sbin/hald subj=system_u:system_r:hald_t:s0 key=(null)

Hash: hald,hald_t,mnt_t,blk_file,getattr

audit2allow

#============= hald_t ==============
allow hald_t mnt_t:blk_file getattr;

audit2allow -R

#============= hald_t ==============
allow hald_t mnt_t:blk_file getattr;

Comment 1 Miroslav Grepl 2011-03-14 15:41:03 UTC
How did you get this? Did you change the label for /dev/sda10?