Bug 1045801

Summary: SELinux is preventing /usr/bin/Xorg from 'search' accesses on the directory 19108.
Product: [Fedora] Fedora Reporter: cyrushmh <cyrusyzgtt>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 20CC: cyrusyzgtt, dominick.grift, dwalsh, lvrabec, mgrepl
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:10bce5528b67ca1e600b76b4c8cd15fd0e0480ded8b369697af0b6539f68106c
Fixed In Version: selinux-policy-3.12.1-116.fc20 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-16 07:10:35 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description cyrushmh 2013-12-22 04:08:35 UTC
Description of problem:
SELinux is preventing /usr/bin/Xorg from 'search' accesses on the directory 19108.

*****  Plugin catchall (100. confidence) suggests   **************************

If 您确定应默认允许 Xorg search 访问 19108 directory。
Then 您应该将这个情况作为 bug 报告。
您可以生成本地策略模块允许这个访问。
Do
请执行以下命令此时允许这个访问:
# grep Xorg /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:bumblebee_t:s0
Target Context                unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1
                              023
Target Objects                19108 [ dir ]
Source                        Xorg
Source Path                   /usr/bin/Xorg
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           xorg-x11-server-Xorg-1.14.4-5.fc20.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-106.fc20.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.12.5-302.fc20.x86_64 #1 SMP Tue
                              Dec 17 20:42:32 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-12-22 11:50:30 CST
Last Seen                     2013-12-22 11:50:30 CST
Local ID                      fb13b225-2821-4580-b7ba-bbd23e4204b4

Raw Audit Messages
type=AVC msg=audit(1387684230.364:974): avc:  denied  { search } for  pid=5456 comm="Xorg" name="19108" dev="proc" ino=1240212 scontext=system_u:system_r:bumblebee_t:s0 tcontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 tclass=dir


type=AVC msg=audit(1387684230.364:974): avc:  denied  { read } for  pid=5456 comm="Xorg" name="cmdline" dev="proc" ino=1239017 scontext=system_u:system_r:bumblebee_t:s0 tcontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 tclass=file


type=AVC msg=audit(1387684230.364:974): avc:  denied  { open } for  pid=5456 comm="Xorg" path="/proc/19108/cmdline" dev="proc" ino=1239017 scontext=system_u:system_r:bumblebee_t:s0 tcontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 tclass=file


type=SYSCALL msg=audit(1387684230.364:974): arch=x86_64 syscall=open success=yes exit=EDOM a0=7fff645c0b80 a1=0 a2=7fff645c0b93 a3=0 items=0 ppid=4731 pid=5456 auid=4294967295 uid=0 gid=1001 euid=0 suid=0 fsuid=0 egid=1001 sgid=1001 fsgid=1001 ses=4294967295 tty=(none) comm=Xorg exe=/usr/bin/Xorg subj=system_u:system_r:bumblebee_t:s0 key=(null)

Hash: Xorg,bumblebee_t,unconfined_t,dir,search

Additional info:
reporter:       libreport-2.1.10
hashmarkername: setroubleshoot
kernel:         3.12.5-302.fc20.x86_64
type:           libreport

Comment 1 Lukas Vrabec 2013-12-23 21:27:49 UTC
Hi, 

Please use: "# restorecon -R /", this should fix your problem.
Be patient it can take a while.

Comment 2 Daniel Walsh 2014-01-02 17:47:24 UTC
No that is not the problem.  The problem here is bumblebee is runing Xorg,which is trying to look at the processes on the system.

unconfined_t is a process label not a file label.  restorecon will have no effect.

Comment 3 Miroslav Grepl 2014-01-06 13:42:37 UTC
And we have bumblebee_t as permissive domain which means we end up with bumblebee_t if Xorg is executed.

Comment 4 Miroslav Grepl 2014-01-06 13:43:38 UTC
What does

# ps -eZ |grep Xorg 

for you?

Comment 5 Miroslav Grepl 2014-01-06 13:47:37 UTC
*** Bug 1046314 has been marked as a duplicate of this bug. ***

Comment 6 Miroslav Grepl 2014-01-06 13:54:50 UTC
*** Bug 1045817 has been marked as a duplicate of this bug. ***

Comment 7 cyrushmh 2014-01-07 08:42:29 UTC
(In reply to Miroslav Grepl from comment #4)
> What does
> 
> # ps -eZ |grep Xorg 
> 
> for you?

system_u:system_r:xserver_t:s0-s0:c0.c1023 1379 tty1 01:16:47 Xorg

Comment 8 Fedora Update System 2014-01-13 22:56:16 UTC
selinux-policy-3.12.1-116.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/selinux-policy-3.12.1-116.fc20

Comment 9 Fedora Update System 2014-01-15 05:57:56 UTC
Package selinux-policy-3.12.1-116.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.12.1-116.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-0806/selinux-policy-3.12.1-116.fc20
then log in and leave karma (feedback).

Comment 10 Fedora Update System 2014-01-16 07:10:35 UTC
selinux-policy-3.12.1-116.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.