Bug 838374 - SELinux is preventing /usr/bin/gdb from using the ptrace access on a gdm-simple-slave with xdm_t
SELinux is preventing /usr/bin/gdb from using the ptrace access on a gdm-simp...
Product: Fedora
Classification: Fedora
Component: gdm (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Ray Strode [halfline]
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-07-08 18:11 EDT by Wendell Baker
Modified: 2013-08-01 06:18 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-08-01 06:18:23 EDT
Type: Bug
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 Wendell Baker 2012-07-08 18:11:52 EDT
Description of problem:

This problem report focuses on the invalid use of gdb to ptrace the failing gdm after firstboot.

The sealert is observed after firstboot

Jul  8 13:16:47 handling setroubleshoot: SELinux is preventing /usr/bin/gdb from using the ptrace access on a process. For complete SELinux messages. run sealert -l 30095de9-5cd9-424c-9e20-939c284203a0

After firstboot, gdm or gdm-simple-slave crashes and an attempt is made to fire up gdb to assess the reason.  This too fails.

How reproducible:


Steps to Reproduce:
1. Install F17
2. Without triggering firstboot, ssh into the box and remediate (details below)
   a. yum update ...
   b. add some users (useradd, usermod)
   c. d not reboot
4. ssh into the box
5. systemctl enable graphical.target
6. systemctl start graphical.target (never finishes)
7. firstboot runs graphically (workflow screens show, but only a spinning wheel, no gdm login)

Actual results:

$ sudo systemctl enable graphical.target
Failed to issue method call: File exists

$ systemctl start graphical.target (never finishes)
<never finishes>

$ systemctl start graphical.target (never finishes)

Expected results:

smooth bringup, without quirks.  This box-build recipe "used to" work (in the F14 & prior days).  The recipe involves pxeboot, tftp+kickstart localnet nfs repo, vnc install followed by ssh as root to add users, yum update, the moral equivalent of "telinit 5" to bring up the graphics.  This is fully automated from bare metal.

1. run the recipe as described until firstboot "hangs"
2. ssh into the box /sbin/reboot
   a. tail /etc/inittab for the telinit recipe
   b. sudo systemctl enable graphical.target ; : just checking
   c. sudo sudo ln -f -s /lib/systemd/system/graphical.target /etc/systemd/system/default.target
   d. sudo systemctl start graphical.target
   e. see gdm, login

Version-Release number of selected component (if applicable):

*after* yum update and *after* reboot


Linux handling 3.4.4-5.fc17.i686.PAE #1 SMP Thu Jul 5 20:09:45 UTC 2012 i686 i686 i386 GNU/Linux

Additional info:

audit2why says:

type=AVC msg=audit(1341778607.114:2677): avc:  denied  { ptrace } for  pid=14105 comm="gdb" scontext=system_u:system_r:xdm_t:s0-s0:c0.c1023 tcontext=system_u:system_r:xdm_t:s0-s0:c0.c1023 tclass=process

	Was caused by:
		Missing type enforcement (TE) allow rule.

		You can use audit2allow to generate a loadable module to allow this access.

See also
systemctl start graphical.target => finishes firstboot but then gdm does not offer a login, only a spinning circle cursor (edit) 

Same problem on F17 from 2012-06-04 (the problem is repeatable).  That problem report focused on the suboptimal error messaging of systemd.  This problem report focuses on the invalid use of gdb to ptrace the failing gdm after firstboot.
Comment 1 Fedora End Of Life 2013-07-03 23:09:09 EDT
This message is a reminder that Fedora 17 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 17. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '17'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 17's end of life.

Bug Reporter:  Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 17 is end of life. If you 
would still like  to see this bug fixed and are able to reproduce it 
against a later version  of Fedora, you are encouraged  change the 
'version' to a later Fedora version prior to Fedora 17's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 2 Fedora End Of Life 2013-08-01 06:18:27 EDT
Fedora 17 changed to end-of-life (EOL) status on 2013-07-30. Fedora 17 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

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