RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 609962 - SELinux is preventing /usr/libexec/gdm-session-worker "read write" access to /home/user
Summary: SELinux is preventing /usr/libexec/gdm-session-worker "read write" access to ...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: selinux-policy
Version: 6.0
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Daniel Walsh
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-07-01 11:14 UTC by Lubos Kocman
Modified: 2010-07-12 20:48 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-07-01 14:57:10 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Lubos Kocman 2010-07-01 11:14:05 UTC
Summary:

SELinux is preventing /usr/libexec/gdm-session-worker "read write" access to
/home/lkocman.

Detailed Description:

[gdm-session-wor has a permissive type (xdm_t). This access was not denied.]

SELinux denied access requested by gdm-session-wor. /home/lkocman may be a
mislabeled. /home/lkocman default SELinux type is user_home_dir_t, but its
current type is home_root_t. Changing this file back to the default type, may
fix your problem.

File contexts can be assigned to a file in the following ways.

  * Files created in a directory receive the file context of the parent
    directory by default.
  * The SELinux policy might override the default label inherited from the
    parent directory by specifying a process running in context A which creates
    a file in a directory labeled B will instead create the file with label C.
    An example of this would be the dhcp client running with the dhclient_t type
    and creating a file in the directory /etc. This file would normally receive
    the etc_t type due to parental inheritance but instead the file is labeled
    with the net_conf_t type because the SELinux policy specifies this.
  * Users can change the file context on a file using tools such as chcon, or
    restorecon.

This file could have been mislabeled either by user error, or if an normally
confined application was run under the wrong domain.

However, this might also indicate a bug in SELinux because the file should not
have been labeled with this type.

If you believe this is a bug, please file a bug report against this package.

Allowing Access:

You can restore the default system context to this file by executing the
restorecon command. restorecon '/home/lkocman', if this file is a directory, you
can recursively restore using restorecon -R '/home/lkocman'.

Fix Command:

/sbin/restorecon '/home/lkocman'

Additional Information:

Source Context                system_u:system_r:xdm_t:s0-s0:c0.c1023
Target Context                unconfined_u:object_r:home_root_t:s0
Target Objects                /home/lkocman [ dir ]
Source                        gdm-session-wor
Source Path                   /usr/libexec/gdm-session-worker
Port                          <Unknown>
Host                          dhcp-27-216.brq.redhat.com
Source RPM Packages           gdm-2.30.2-9.el6
Target RPM Packages           
Policy RPM                    selinux-policy-3.7.19-27.el6
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   restorecon
Host Name                     dhcp-27-216.brq.redhat.com
Platform                      Linux dhcp-27-216.brq.redhat.com
                              2.6.32-37.el6pcmring1.x86_64 #1 SMP Wed Jun 23
                              08:36:36 EDT 2010 x86_64 x86_64
Alert Count                   4
First Seen                    Wed 30 Jun 2010 11:08:24 AM CEST
Last Seen                     Thu 01 Jul 2010 09:19:23 AM CEST
Local ID                      6c85c516-2066-43f8-b906-ed2f08b8cdcc
Line Numbers                  

Raw Audit Messages            

node=dhcp-27-216.brq.redhat.com type=AVC msg=audit(1277968763.202:16): avc:  denied  { read write } for  pid=8976 comm="gdm-session-wor" name="lkocman" dev=dm-3 ino=258 scontext=system_u:system_r:xdm_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:home_root_t:s0 tclass=dir

node=dhcp-27-216.brq.redhat.com type=SYSCALL msg=audit(1277968763.202:16): arch=c000003e syscall=21 success=yes exit=68719476864 a0=776b60 a1=7 a2=20 a3=a0 items=0 ppid=8958 pid=8976 auid=500 uid=500 gid=100 euid=500 suid=500 fsuid=500 egid=100 sgid=100 fsgid=100 tty=(none) ses=1 comm="gdm-session-wor" exe="/usr/libexec/gdm-session-worker" subj=system_u:system_r:xdm_t:s0-s0:c0.c1023 key=(null)



Additional info:

bash-4.1$ ls -ladZ /home/lkocman
drwx------. lkocman users unconfined_u:object_r:home_root_t:s0 /home/lkocman

Comment 2 RHEL Program Management 2010-07-01 11:23:11 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.

Comment 3 Miroslav Grepl 2010-07-01 14:57:10 UTC
Lubos,
execute

restorecon -R -v /home

Should fix. Not sure how it happened.


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