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 987778 - selinux prevents dyntransition with sshd
Summary: selinux prevents dyntransition with sshd
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: selinux-policy
Version: 7.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: rc
: ---
Assignee: Miroslav Grepl
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-24 07:11 UTC by David Spurek
Modified: 2015-03-02 05:27 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-24 08:18:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description David Spurek 2013-07-24 07:11:22 UTC
Description of problem:
selinux prevents dyntransition with sshd.

ausearch output:

----
time->Wed Jul 24 02:24:21 2013
type=SYSCALL msg=audit(1374647061.593:2024): arch=c000003e syscall=1 success=no exit=-13 a0=8 a1=7fa07e96e590 a2=36 a3=666e6f636e753a72 items=0 ppid=25992 pid=26005 auid=0 uid=9999 gid=9999 euid=9999 suid=9999 fsuid=9999 egid=9999 sgid=9999 fsgid=9999 ses=70 tty=pts0 comm="sshd" exe="/usr/sbin/sshd" subj=unconfined_u:system_r:unconfined_t:s0-s0:c0.c1023 key=(null)
type=AVC msg=audit(1374647061.593:2024): avc:  denied  { dyntransition } for  pid=26005 comm="sshd" scontext=unconfined_u:system_r:unconfined_t:s0-s0:c0.c1023 tcontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 tclass=process

part of log from sshd server:

debug1: SELinux support enabled [preauth]
debug3: ssh_selinux_change_context: setting context from 'unconfined_u:system_r:
unconfined_t:s0-s0:c0.c1023' to 'unconfined_u:system_r:sshd_net_t:s0-s0:c0.c1023
' [preauth]
debug3: ssh_selinux_change_context: setcon unconfined_u:system_r:sshd_net_t:s0-s
0:c0.c1023 from unconfined_u:system_r:unconfined_t:s0-s0:c0.c1023 failed with Pe
rmission denied [preauth]

Version-Release number of selected component (if applicable):
selinux-policy-3.12.1-63.el7
openssh-6.2p2-3.el7

How reproducible:
always

Steps to Reproduce:
1.run reproduce test
2.
3.

Actual results:
AVC message, in log of ssh server i see - ssh_selinux_change_context: failed with Permission denied [preauth] 

Expected results:
no AVC message, no problem with ssh_selinux_change_context in sshd log

Additional info:

Comment 2 Miroslav Grepl 2013-07-24 08:18:54 UTC
David,
basically it means that the sshd daemon is running with the bad context. Did you start it by hand?

Are you trying to debug sshd?


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