Bug 689635

Summary: SELinux is preventing /bin/systemd-notify from 'write' accesses on the directory .systemd.
Product: [Fedora] Fedora Reporter: Paul Lange <palango>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 15CC: dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:4070265d6156e1d5c85e584452aa24a561b9c3857148f36d2e9df401e6319705
Fixed In Version: selinux-policy-3.9.16-6.fc15 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-03-25 07:04:15 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Paul Lange 2011-03-21 23:33:42 UTC
SELinux is preventing /bin/systemd-notify from 'write' accesses on the directory .systemd.

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

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

Additional Information:
Source Context                system_u:system_r:systemd_notify_t:s0
Target Context                system_u:object_r:device_t:s0
Target Objects                .systemd [ dir ]
Source                        systemd-notify
Source Path                   /bin/systemd-notify
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           systemd-20-1.fc15
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.16-1.fc15
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 2.6.38-0.rc8.git0.1.fc15.i686 #1 SMP
                              Tue Mar 8 08:24:57 UTC 2011 i686 i686
Alert Count                   2
First Seen                    Mon 21 Mar 2011 11:58:42 PM CET
Last Seen                     Tue 22 Mar 2011 12:06:09 AM CET
Local ID                      bdf533fd-7d35-432e-8616-6a3bc8a88d1f

Raw Audit Messages
type=AVC msg=audit(1300748769.433:40): avc:  denied  { write } for  pid=1025 comm="systemd-notify" name=".systemd" dev=devtmpfs ino=6381 scontext=system_u:system_r:systemd_notify_t:s0 tcontext=system_u:object_r:device_t:s0 tclass=dir


type=AVC msg=audit(1300748769.433:40): avc:  denied  { add_name } for  pid=1025 comm="systemd-notify" name="readahead" scontext=system_u:system_r:systemd_notify_t:s0 tcontext=system_u:object_r:device_t:s0 tclass=dir


type=AVC msg=audit(1300748769.433:40): avc:  denied  { create } for  pid=1025 comm="systemd-notify" name="readahead" scontext=system_u:system_r:systemd_notify_t:s0 tcontext=system_u:object_r:device_t:s0 tclass=dir


type=SYSCALL msg=audit(1300748769.433:40): arch=i386 syscall=mkdir success=yes exit=0 a0=804cc1e a1=1ed a2=804cc3d a3=2 items=0 ppid=1 pid=1025 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=systemd-notify exe=/bin/systemd-notify subj=system_u:system_r:systemd_notify_t:s0 key=(null)

Hash: systemd-notify,systemd_notify_t,device_t,dir,write

audit2allow

#============= systemd_notify_t ==============
allow systemd_notify_t device_t:dir { write create add_name };

audit2allow -R

#============= systemd_notify_t ==============
allow systemd_notify_t device_t:dir { write create add_name };

Comment 1 Daniel Walsh 2011-03-22 11:55:27 UTC
selinux-policy-3.9.16-6.fc15

Comment 2 Fedora Update System 2011-03-22 23:07:33 UTC
selinux-policy-3.9.16-6.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/selinux-policy-3.9.16-6.fc15

Comment 3 Fedora Update System 2011-03-25 07:03:59 UTC
selinux-policy-3.9.16-6.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.