Bug 710817

Summary: SELinux is preventing /usr/libexec/ck-get-x11-server-pid from 'getattr' accesses on the file /var/run/gdm/auth-for-gdm-aOuZeS/database.
Product: [Fedora] Fedora Reporter: Daniel Demus <daniel>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 15CC: daniel, dominick.grift, dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:87071d25a8a55edcea17b78130d7bc7051ea81e9f1738389f2851a374998de12
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-06-05 07:51: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 Daniel Demus 2011-06-05 00:28:12 UTC
SELinux is preventing /usr/libexec/ck-get-x11-server-pid from 'getattr' accesses on the file /var/run/gdm/auth-for-gdm-aOuZeS/database.

*****  Plugin restorecon (99.5 confidence) suggests  *************************

If you want to fix the label. 
/var/run/gdm/auth-for-gdm-aOuZeS/database default label should be xdm_var_run_t.
Then you can run restorecon.
Do
# /sbin/restorecon -v /var/run/gdm/auth-for-gdm-aOuZeS/database

*****  Plugin catchall (1.49 confidence) suggests  ***************************

If you believe that ck-get-x11-server-pid should be allowed getattr access on the database 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 ck-get-x11-serv /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:consolekit_t:s0
Target Context                unconfined_u:object_r:var_run_t:s0
Target Objects                /var/run/gdm/auth-for-gdm-aOuZeS/database [ file ]
Source                        ck-get-x11-serv
Source Path                   /usr/libexec/ck-get-x11-server-pid
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           ConsoleKit-x11-0.4.5-1.fc15
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.16-26.fc15
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Host Name                     (removed)
Platform                      Linux (removed) 2.6.38.6-27.fc15.x86_64 #1 SMP
                              Sun May 15 17:23:28 UTC 2011 x86_64 x86_64
Alert Count                   1
First Seen                    Sun 05 Jun 2011 02:26:21 CEST
Last Seen                     Sun 05 Jun 2011 02:26:21 CEST
Local ID                      9666c37e-9e6f-4d52-82ee-6a4614673db4

Raw Audit Messages
type=AVC msg=audit(1307233581.568:60): avc:  denied  { getattr } for  pid=1484 comm="ck-get-x11-serv" path="/var/run/gdm/auth-for-gdm-aOuZeS/database" dev=tmpfs ino=19893 scontext=system_u:system_r:consolekit_t:s0 tcontext=unconfined_u:object_r:var_run_t:s0 tclass=file


type=SYSCALL msg=audit(1307233581.568:60): arch=x86_64 syscall=fstat success=yes exit=0 a0=4 a1=7ffff1e648d0 a2=7ffff1e648d0 a3=ffffffffffffffab items=0 ppid=1483 pid=1484 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=ck-get-x11-serv exe=/usr/libexec/ck-get-x11-server-pid subj=system_u:system_r:consolekit_t:s0 key=(null)

Hash: ck-get-x11-serv,consolekit_t,var_run_t,file,getattr

audit2allow

#============= consolekit_t ==============
allow consolekit_t var_run_t:file getattr;

audit2allow -R

#============= consolekit_t ==============
allow consolekit_t var_run_t:file getattr;

Comment 1 Miroslav Grepl 2011-06-05 07:51:34 UTC

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