Bug 747309

Summary: SELinux is preventing /usr/libexec/kde4/kcmdatetimehelper from 'read' accesses on the directory /.kde/share/config.
Product: [Fedora] Fedora Reporter: Mircea Sava <msava>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: rawhideCC: dominick.grift, dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:6317a2eaebc65b2df4f29c4542308f429f22e194ae8d49d78c3b99f1fa045ed0
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-10-19 13:16:03 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 Mircea Sava 2011-10-19 13:10:05 UTC
SELinux is preventing /usr/libexec/kde4/kcmdatetimehelper from 'read' accesses on the directory /.kde/share/config.

*****  Plugin catchall_labels (83.8 confidence) suggests  ********************

If you want to allow kcmdatetimehelper to have read access on the config directory
Then you need to change the label on /.kde/share/config
Do
# semanage fcontext -a -t FILE_TYPE '/.kde/share/config'
where FILE_TYPE is one of the following: root_t, usr_t, device_t, etc_t, net_conf_t, textrel_shlib_t, config_usr_t, gnomeclock_t, var_run_t, bin_t, cert_t, usr_t, locale_t, etc_t, proc_t, sysctl_crypto_t, dbusd_etc_t, abrt_t, lib_t, net_conf_t, nscd_var_run_t, cert_t, var_lib_t. 
Then execute: 
restorecon -v '/.kde/share/config'


*****  Plugin catchall (17.1 confidence) suggests  ***************************

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

Additional Information:
Source Context                system_u:system_r:gnomeclock_t:s0-s0:c0.c1023
Target Context                system_u:object_r:default_t:s0
Target Objects                /.kde/share/config [ dir ]
Source                        kcmdatetimehelp
Source Path                   /usr/libexec/kde4/kcmdatetimehelper
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           kdebase-workspace-4.6.5-5.fc15
Target RPM Packages           
Policy RPM                    selinux-policy-3.9.16-39.fc15
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 2.6.40.6-0.fc15.i686
                              #1 SMP Tue Oct 4 00:51:19 UTC 2011 i686 i686
Alert Count                   9
First Seen                    Wed 19 Oct 2011 03:39:03 PM EEST
Last Seen                     Wed 19 Oct 2011 03:43:10 PM EEST
Local ID                      45a9969d-0605-46a9-a8de-205189f3e184

Raw Audit Messages
type=AVC msg=audit(1319027943.775:157): avc:  denied  { read } for  pid=4935 comm="kcmdatetimehelp" name="config" dev=dm-1 ino=2752518 scontext=system_u:system_r:gnomeclock_t:s0-s0:c0.c1023 tcontext=system_u:object_r:default_t:s0 tclass=dir


type=SYSCALL msg=audit(1319027943.775:157): arch=i386 syscall=access success=no exit=EACCES a0=81331e0 a1=4 a2=49ff8430 a3=bfa54ab4 items=0 ppid=1 pid=4935 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=kcmdatetimehelp exe=/usr/libexec/kde4/kcmdatetimehelper subj=system_u:system_r:gnomeclock_t:s0-s0:c0.c1023 key=(null)

Hash: kcmdatetimehelp,gnomeclock_t,default_t,dir,read

audit2allow

#============= gnomeclock_t ==============
allow gnomeclock_t default_t:dir read;

audit2allow -R

#============= gnomeclock_t ==============
allow gnomeclock_t default_t:dir read;

Comment 1 Miroslav Grepl 2011-10-19 13:16:03 UTC

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