Bug 1001809 - SELinux is preventing /usr/libexec/colord from 'search' accesses on the directory /home/jrtv.
SELinux is preventing /usr/libexec/colord from 'search' accesses on the direc...
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Lukas Vrabec
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-08-27 15:45 EDT by Odysseys
Modified: 2013-08-28 15:14 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-08-28 15:14:32 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Odysseys 2013-08-27 15:45:20 EDT
Description of problem:
I configured postinstall routines with 'easylife' and I wanted colors in my terminal.
After I rebooted my machine, this came up. I tried to allow access for now, like help text shows me, but it didn't work right: (I ran it as a root)

"grep colord /var/log/audit.log | audit2allow -M mypol
grep: /var/log/audit.log: No such file or directory
bash: audit2allow: command not found..."
SELinux is preventing /usr/libexec/colord from 'search' accesses on the directory /home/jrtv.

*****  Plugin file (36.8 confidence) suggests  *******************************

If you think this is caused by a badly mislabeled machine.
Then you need to fully relabel.
touch /.autorelabel; reboot

*****  Plugin file (36.8 confidence) suggests  *******************************

If you think this is caused by a badly mislabeled machine.
Then you need to fully relabel.
touch /.autorelabel; reboot

*****  Plugin catchall_labels (23.2 confidence) suggests  ********************

If you want to allow colord to have search access on the jrtv directory
Then you need to change the label on /home/jrtv
# semanage fcontext -a -t FILE_TYPE '/home/jrtv'
where FILE_TYPE is one of the following: abrt_var_run_t, alsa_home_t, anon_inodefs_t, audio_home_t, auth_home_t, autofs_t, avahi_var_run_t, bin_t, binfmt_misc_fs_t, boot_t, cache_home_t, capifs_t, cert_t, cgroup_t, chrome_sandbox_home_t, cifs_t, colord_tmp_t, colord_tmpfs_t, colord_var_lib_t, config_home_t, cpu_online_t, cupsd_etc_t, cupsd_var_run_t, data_home_t, dbus_home_t, dbusd_etc_t, debugfs_t, default_context_t, default_t, device_t, devpts_t, dosfs_t, ecryptfs_t, efivarfs_t, etc_t, fail2ban_var_lib_t, fetchmail_home_t, file_context_t, fusefs_t, gconf_home_t, git_user_content_t, gkeyringd_gnome_home_t, gnome_home_t, gpg_secret_t, gstreamer_home_t, home_bin_t, home_cert_t, home_root_t, httpd_sys_content_t, httpd_user_content_t, httpd_user_htaccess_t, httpd_user_ra_content_t, httpd_user_rw_content_t, httpd_user_script_exec_t, hugetlbfs_t, icc_data_home_t, iceauth_home_t, init_var_run_t, irc_home_t, irc_tmp_t, irssi_home_t, iso9660_t, kismet_home_t, krb5_conf_t, krb5_home_t, krb5_host_rcache_t, lib_t, likewise_var_lib_t, local_login_home_t, locale_t, mail_home_rw_t, mail_home_t, man_cache_t, man_t, mandb_cache_t, mandb_home_t, mnt_t, mozilla_home_t, mpd_user_data_t, mplayer_home_t, mysqld_home_t, net_conf_t, nfs_t, nfsd_fs_t, nscd_var_run_t, nslcd_var_run_t, openshift_var_lib_t, oracleasmfs_t, pcscd_var_run_t, policykit_reload_t, policykit_var_lib_t, polipo_cache_home_t, polipo_config_home_t, proc_t, procmail_home_t, pulseaudio_home_t, ramfs_t, removable_t, rlogind_home_t, root_t, rpc_pipefs_t, rpm_log_t, rpm_script_tmp_t, rssh_ro_t, rssh_rw_t, samba_etc_t, samba_var_t, screen_home_t, security_t, selinux_config_t, setrans_var_run_t, shell_exec_t, smbd_var_run_t, sosreport_tmp_t, spamc_home_t, spufs_t, src_t, ssh_home_t, sssd_public_t, sssd_var_lib_t, svirt_home_t, svirt_lxc_file_t, sysctl_t, sysfs_t, syslogd_var_run_t, system_cronjob_var_lib_t, system_dbusd_var_lib_t, system_dbusd_var_run_t, systemd_logind_sessions_t, sysv_t, telepathy_cache_home_t, telepathy_data_home_t, telepathy_gabble_cache_home_t, telepathy_logger_cache_home_t, telepathy_logger_data_home_t, telepathy_mission_control_cache_home_t, telepathy_mission_control_data_home_t, telepathy_mission_control_home_t, telepathy_sunshine_home_t, textrel_shlib_t, thumb_home_t, tmp_t, tmpfs_t, tvtime_home_t, udev_var_run_t, uml_ro_t, uml_rw_t, usbfs_t, user_fonts_cache_t, user_fonts_config_t, user_fonts_t, user_home_dir_t, user_home_t, user_tmp_t, user_tmpfs_t, usr_t, var_lib_t, var_log_t, var_run_t, var_t, virt_content_t, virt_home_t, vmblock_t, vmware_conf_t, vmware_file_t, vxfs_t, winbind_var_run_t, wine_home_t, wireshark_home_t, xauth_home_t, xdm_home_t, xdm_var_run_t, xenfs_t, zoneminder_tmpfs_t. 
Then execute: 
restorecon -v '/home/jrtv'

*****  Plugin catchall (5.04 confidence) suggests  ***************************

If you believe that colord should be allowed search access on the jrtv directory by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
allow this access for now by executing:
# grep colord /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:colord_t:s0
Target Context                system_u:object_r:file_t:s0
Target Objects                /home/jrtv [ dir ]
Source                        colord
Source Path                   /usr/libexec/colord
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           colord-1.0.3-1.fc19.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-73.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.10.9-200.fc19.x86_64 #1 SMP Wed
                              Aug 21 19:27:58 UTC 2013 x86_64 x86_64
Alert Count                   3
First Seen                    2013-08-27 08:24:40 EEST
Last Seen                     2013-08-28 01:33:00 EEST
Local ID                      c8151fe2-a9d7-4d67-98a3-eee76aa84cc1

Raw Audit Messages
type=AVC msg=audit(1377642780.805:212): avc:  denied  { search } for  pid=1060 comm="colord" name="jrtv" dev="sda3" ino=16121857 scontext=system_u:system_r:colord_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=dir

type=SYSCALL msg=audit(1377642780.805:212): arch=x86_64 syscall=open success=no exit=EACCES a0=7fddbb12fc60 a1=0 a2=0 a3=aaaaaaaaaaaaaaab items=0 ppid=1 pid=1060 auid=4294967295 uid=998 gid=997 euid=998 suid=998 fsuid=998 egid=997 sgid=997 fsgid=997 ses=4294967295 tty=(none) comm=colord exe=/usr/libexec/colord subj=system_u:system_r:colord_t:s0 key=(null)

Hash: colord,colord_t,file_t,dir,search

Additional info:
reporter:       libreport-2.1.6
hashmarkername: setroubleshoot
kernel:         3.10.9-200.fc19.x86_64
type:           libreport
Comment 1 Lukas Vrabec 2013-08-28 05:29:53 EDT

Could you try: "restorecon -R /home/jrtv" .
Comment 2 ricardo.salaya 2013-08-28 11:49:20 EDT
Description of problem:
I dont know

Additional info:
reporter:       libreport-2.1.6
hashmarkername: setroubleshoot
kernel:         3.10.9-200.fc19.x86_64
type:           libreport
Comment 3 Daniel Walsh 2013-08-28 15:14:16 EDT
Ricardo, your home dir does not have any labels on it.


# restorecon -R -v /home 

as root will place labels on it, and fix your problem.

Note You need to log in before you can comment on or make changes to this bug.