Bug 740404

Summary: SELinux is preventing /usr/bin/kdm from 'create' accesses on the file .Xauthority-c.
Product: [Fedora] Fedora Reporter: Minh Ngo <nlminhtl>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 15CC: dominick.grift, dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:a2bca5453988d0c697851024e278b82f127d216f85e8c36dee94b657a3ee064e
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-09-22 08:51:27 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 Minh Ngo 2011-09-21 22:23:40 UTC
SELinux is preventing /usr/bin/kdm from 'create' accesses on the file .Xauthority-c.

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

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

Additional Information:
Source Context                system_u:system_r:xdm_t:s0-s0:c0.c1023
Target Context                system_u:object_r:admin_home_t:s0
Target Objects                .Xauthority-c [ file ]
Source                        kdm
Source Path                   /usr/bin/kdm
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           kdm-4.7.0-6.fc15
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.16-38.fc15
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 2.6.40.4-5.fc15.x86_64 #1 SMP Tue
                              Aug 30 14:38:32 UTC 2011 x86_64 x86_64
Alert Count                   3
First Seen                    Mon 19 Sep 2011 12:50:01 AM EEST
Last Seen                     Mon 19 Sep 2011 12:50:18 AM EEST
Local ID                      e083d813-4de1-4acc-855c-20629c930e83

Raw Audit Messages
type=AVC msg=audit(1316382618.362:77): avc:  denied  { create } for  pid=2436 comm="kdm" name=".Xauthority-c" scontext=system_u:system_r:xdm_t:s0-s0:c0.c1023 tcontext=system_u:object_r:admin_home_t:s0 tclass=file


type=SYSCALL msg=audit(1316382618.362:77): arch=x86_64 syscall=open success=no exit=EACCES a0=7fff69a58150 a1=c1 a2=180 a3=7fff69a58560 items=0 ppid=2071 pid=2436 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=2 comm=kdm exe=/usr/bin/kdm subj=system_u:system_r:xdm_t:s0-s0:c0.c1023 key=(null)

Hash: kdm,xdm_t,admin_home_t,file,create

audit2allow

#============= xdm_t ==============
allow xdm_t admin_home_t:file create;

audit2allow -R

#============= xdm_t ==============
allow xdm_t admin_home_t:file create;

Comment 1 Miroslav Grepl 2011-09-22 08:51:27 UTC
Do you log in via X as root?

Since SELinux does not support logging in as root, I am closing this bugzilla.