Bug 912616

Summary: SELinux is preventing /usr/lib/systemd/systemd-hostnamed from 'search' accesses on the directory journal.
Product: [Fedora] Fedora Reporter: ali <alihosseini65>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 18CC: dominick.grift, dwalsh, mgrepl, shrijit.panicker
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:890ee78179b00bf65c53764ac518febd963dec16fe6b8ff7be4713d9b7d5c175
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-20 04:01:57 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 ali 2013-02-19 08:16:12 UTC
Description of problem:
SELinux is preventing /usr/lib/systemd/systemd-hostnamed from 'search' accesses on the directory journal.

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

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

Additional Information:
Source Context                system_u:system_r:systemd_hostnamed_t:s0
Target Context                system_u:object_r:syslogd_var_run_t:s0
Target Objects                journal [ dir ]
Source                        systemd-hostnam
Source Path                   /usr/lib/systemd/systemd-hostnamed
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           systemd-197-1.fc18.1.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.11.1-78.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.7.8-202.fc18.x86_64 #1 SMP Fri
                              Feb 15 17:33:07 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-02-19 11:44:47 IRST
Last Seen                     2013-02-19 11:44:47 IRST
Local ID                      2aaab31a-9e41-435f-9e0d-d1f6c91615cd

Raw Audit Messages
type=AVC msg=audit(1361261687.532:534): avc:  denied  { search } for  pid=23913 comm="systemd-hostnam" name="journal" dev="tmpfs" ino=8313 scontext=system_u:system_r:systemd_hostnamed_t:s0 tcontext=system_u:object_r:syslogd_var_run_t:s0 tclass=dir


type=SYSCALL msg=audit(1361261687.532:534): arch=x86_64 syscall=connect success=no exit=EACCES a0=3 a1=7fff819930a0 a2=1d a3=7fff81993058 items=0 ppid=1 pid=23913 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=4294967295 tty=(none) comm=systemd-hostnam exe=/usr/lib/systemd/systemd-hostnamed subj=system_u:system_r:systemd_hostnamed_t:s0 key=(null)

Hash: systemd-hostnam,systemd_hostnamed_t,syslogd_var_run_t,dir,search

audit2allow

#============= systemd_hostnamed_t ==============
allow systemd_hostnamed_t syslogd_var_run_t:dir search;

audit2allow -R

#============= systemd_hostnamed_t ==============
allow systemd_hostnamed_t syslogd_var_run_t:dir search;


Additional info:
hashmarkername: setroubleshoot
kernel:         3.7.8-202.fc18.x86_64
type:           libreport

Comment 1 Miroslav Grepl 2013-02-19 09:23:12 UTC
Fixed in selinux-policy-3.11.1-79.fc18

Comment 2 Fedora Update System 2013-02-19 09:30:12 UTC
selinux-policy-3.11.1-79.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/selinux-policy-3.11.1-79.fc18

Comment 3 Fedora Update System 2013-02-20 04:02:00 UTC
selinux-policy-3.11.1-79.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 4 Miroslav Grepl 2013-02-20 06:40:01 UTC
*** Bug 912811 has been marked as a duplicate of this bug. ***