Bug 741018

Summary: SELinux is preventing /bin/systemctl from 'getattr' accesses on the directory /lib/systemd/system.
Product: [Fedora] Fedora Reporter: Matthias Andree <matthias.andree>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 16CC: chmelarz, dominick.grift, dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:3f7e425a0710e482131f65e5edbf459637ed46b8427f0a79ad295c153ee66466
Fixed In Version: selinux-policy-3.10.0-38.fc16 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-10-09 19:36:11 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Matthias Andree 2011-09-24 13:28:10 UTC
abrt version: 2.0.5.980
executable:     /usr/bin/python
hashmarkername: setroubleshoot
kernel:         3.1.0-0.rc6.git0.3.fc16.x86_64
reason:         SELinux is preventing /bin/systemctl from 'getattr' accesses on the directory /lib/systemd/system.
time:           Sat Sep 24 15:27:20 2011

description:
:SELinux is preventing /bin/systemctl from 'getattr' accesses on the directory /lib/systemd/system.
:
:*****  Plugin catchall (100. confidence) suggests  ***************************
:
:If you believe that systemctl should be allowed getattr access on the system directory 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 systemctl /var/log/audit/audit.log | audit2allow -M mypol
:# semodule -i mypol.pp
:
:Additional Information:
:Source Context                system_u:system_r:gnomeclock_systemctl_t:s0-s0:c0.
:                              c1023
:Target Context                system_u:object_r:systemd_unit_file_t:s0
:Target Objects                /lib/systemd/system [ dir ]
:Source                        systemctl
:Source Path                   /bin/systemctl
:Port                          <Unknown>
:Host                          (removed)
:Source RPM Packages           systemd-units-35-1.fc16
:Target RPM Packages           systemd-units-35-1.fc16
:Policy RPM                    selinux-policy-3.10.0-32.fc16
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Enforcing
:Host Name                     (removed)
:Platform                      Linux (removed) 3.1.0-0.rc6.git0.3.fc16.x86_64 #1
:                              SMP Fri Sep 16 12:26:22 UTC 2011 x86_64 x86_64
:Alert Count                   1
:First Seen                    Sat 24 Sep 2011 03:26:50 PM CEST
:Last Seen                     Sat 24 Sep 2011 03:26:50 PM CEST
:Local ID                      5df65310-0e08-4ee5-9482-6e9750642732
:
:Raw Audit Messages
:type=AVC msg=audit(1316870810.802:210): avc:  denied  { getattr } for  pid=8318 comm="systemctl" path="/lib/systemd/system" dev=dm-1 ino=11114 scontext=system_u:system_r:gnomeclock_systemctl_t:s0-s0:c0.c1023 tcontext=system_u:object_r:systemd_unit_file_t:s0 tclass=dir
:
:
:type=SYSCALL msg=audit(1316870810.802:210): arch=x86_64 syscall=lstat success=no exit=EACCES a0=cbd690 a1=7fff24abe610 a2=7fff24abe610 a3=0 items=0 ppid=8296 pid=8318 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=systemctl exe=/bin/systemctl subj=system_u:system_r:gnomeclock_systemctl_t:s0-s0:c0.c1023 key=(null)
:
:Hash: systemctl,gnomeclock_systemctl_t,systemd_unit_file_t,dir,getattr
:
:audit2allow
:
:#============= gnomeclock_systemctl_t ==============
:allow gnomeclock_systemctl_t systemd_unit_file_t:dir getattr;
:
:audit2allow -R
:
:#============= gnomeclock_systemctl_t ==============
:allow gnomeclock_systemctl_t systemd_unit_file_t:dir getattr;
:

Comment 1 Miroslav Grepl 2011-09-26 08:15:42 UTC
Fixed in selinux-policy-3.10.0-34.fc16

Comment 2 Fedora Update System 2011-10-04 11:17:09 UTC
selinux-policy-3.10.0-36.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/selinux-policy-3.10.0-36.fc16

Comment 3 Fedora Update System 2011-10-04 20:49:56 UTC
Package selinux-policy-3.10.0-36.fc16:
* should fix your issue,
* was pushed to the Fedora 16 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.10.0-36.fc16'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/selinux-policy-3.10.0-36.fc16
then log in and leave karma (feedback).

Comment 4 Zdenek Chmelar 2011-10-05 19:36:03 UTC
After the update to required version, the error didn't appear anymore. But new bug was introduced instead of that (reported on https://bugzilla.redhat.com/show_bug.cgi?id=743701).

Comment 5 Fedora Update System 2011-10-09 19:36:11 UTC
selinux-policy-3.10.0-38.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.