Bug 1285180

Summary: SELinux is preventing abrt-dump-journ from 'execute' accesses on the file /usr/bin/Xorg.
Product: [Fedora] Fedora Reporter: Alexander Kurtakov <akurtako>
Component: selinux-policyAssignee: Lukas Vrabec <lvrabec>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: medium    
Version: 23CC: arik, beland, bugzilla, cyberalex4life, dominick.grift, dwalsh, edosurina, fraph24, fulminemizzega, gkadam, idkypa, jamescape777, jberan, lvrabec, martincigorraga, mgrepl, mikhail.v.gavrilov, milan.kerslager, nilsonnetonapn, plautrba, rupatel, sheepdestroyer, shenada, thomas.howard, vikigoyal, vpvainio
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:009c43335001ee218f60e2147499b5bb982e185fd454652a11a615f6e14a15fa;VARIANT_ID=workstation;
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-20 16:15:22 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 Alexander Kurtakov 2015-11-25 07:59:03 UTC
Description of problem:
SELinux is preventing abrt-dump-journ from 'execute' accesses on the file /usr/bin/Xorg.

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

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

Additional Information:
Source Context                system_u:system_r:abrt_dump_oops_t:s0
Target Context                system_u:object_r:xserver_exec_t:s0
Target Objects                /usr/bin/Xorg [ file ]
Source                        abrt-dump-journ
Source Path                   abrt-dump-journ
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           xorg-x11-server-Xorg-1.18.0-2.fc23.x86_64
Policy RPM                    selinux-policy-3.13.1-155.fc23.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.2.6-300.fc23.x86_64 #1 SMP Tue
                              Nov 10 19:32:21 UTC 2015 x86_64 x86_64
Alert Count                   10
First Seen                    2015-11-25 09:58:20 EET
Last Seen                     2015-11-25 09:58:29 EET
Local ID                      e7578b4b-513c-449d-b12e-f3871ad7d3bd

Raw Audit Messages
type=AVC msg=audit(1448438309.300:1476): avc:  denied  { execute } for  pid=17370 comm="abrt-dump-journ" name="Xorg" dev="dm-2" ino=794321 scontext=system_u:system_r:abrt_dump_oops_t:s0 tcontext=system_u:object_r:xserver_exec_t:s0 tclass=file permissive=0


Hash: abrt-dump-journ,abrt_dump_oops_t,xserver_exec_t,file,execute

Version-Release number of selected component:
selinux-policy-3.13.1-155.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.6-300.fc23.x86_64
type:           libreport

Comment 1 Francesco Frassinelli (frafra) 2015-11-25 11:07:06 UTC
Description of problem:
I was upgrading my system, including Xorg, to updates-testing. Everything seems to work correctly.

Version-Release number of selected component:
selinux-policy-3.13.1-155.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.5-300.fc23.x86_64
type:           libreport

Comment 2 Ville-Pekka Vainio 2015-11-28 11:29:57 UTC
Description of problem:
This happened during a dnf update.

Version-Release number of selected component:
selinux-policy-3.13.1-155.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.6-300.fc23.x86_64
type:           libreport

Comment 3 fulminemizzega 2015-11-29 16:30:05 UTC
Got this after upgrading with dnf, this is what dnf installed/updated:
Installed:
  fwupdate-efi.x86_64 0.5-3.fc23                                                

Updated:
  abrt.x86_64 2.7.1-1.fc23                                                      
  abrt-addon-ccpp.x86_64 2.7.1-1.fc23                                           
  abrt-addon-coredump-helper.x86_64 2.7.1-1.fc23                                
  abrt-addon-kerneloops.x86_64 2.7.1-1.fc23                                     
  abrt-addon-pstoreoops.x86_64 2.7.1-1.fc23                                     
  abrt-addon-python.x86_64 2.7.1-1.fc23                                         
  abrt-addon-python3.x86_64 2.7.1-1.fc23                                        
  abrt-addon-vmcore.x86_64 2.7.1-1.fc23                                         
  abrt-addon-xorg.x86_64 2.7.1-1.fc23                                           
  abrt-cli.x86_64 2.7.1-1.fc23                                                  
  abrt-dbus.x86_64 2.7.1-1.fc23                                                 
  abrt-desktop.x86_64 2.7.1-1.fc23                                              
  abrt-gui.x86_64 2.7.1-1.fc23                                                  
  abrt-gui-libs.x86_64 2.7.1-1.fc23                                             
  abrt-libs.x86_64 2.7.1-1.fc23                                                 
  abrt-plugin-bodhi.x86_64 2.7.1-1.fc23                                         
  abrt-python.x86_64 2.7.1-1.fc23                                               
  abrt-python3.x86_64 2.7.1-1.fc23                                              
  abrt-retrace-client.x86_64 2.7.1-1.fc23                                       
  abrt-tui.x86_64 2.7.1-1.fc23                                                  
  dnf.noarch 1.1.4-2.fc23                                                       
  dnf-conf.noarch 1.1.4-2.fc23                                                  
  dnf-yum.noarch 1.1.4-2.fc23                                                   
  fwupd.x86_64 0.5.4-1.fc23                                                     
  fwupdate-libs.x86_64 0.5-3.fc23                                               
  libappstream-glib.x86_64 0.5.4-1.fc23                                         
  mock.noarch 1.2.14-1.fc23                                                     
  python2-dnf.noarch 1.1.4-2.fc23                                               
  python3-dnf.noarch 1.1.4-2.fc23

Comment 4 vikram goyal 2015-12-16 05:42:47 UTC
Description of problem:

This is system generated avc. I think it should work by default.

Version-Release number of selected component:
selinux-policy-3.13.1-155.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.6-301.fc23.x86_64
type:           libreport

Comment 5 vikram goyal 2015-12-24 11:40:36 UTC
Description of problem:

It seems that default policy needs some adjustment.

Version-Release number of selected component:
selinux-policy-3.13.1-157.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.8-300.fc23.x86_64
type:           libreport

Comment 6 Aleksey 2016-01-13 21:07:24 UTC
Description of problem:
selinux alert just poped up while I was upgrading fedora from 22 to 23

Version-Release number of selected component:
selinux-policy-3.13.1-158.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.8-200.fc22.x86_64
type:           libreport

Comment 7 vikram goyal 2016-01-25 10:27:10 UTC
Description of problem:

system generated. Seems needs some tweaking.

Version-Release number of selected component:
selinux-policy-3.13.1-158.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.3.3-301.fc23.x86_64
type:           libreport

Comment 8 Miroslav Grepl 2016-05-05 20:12:37 UTC
Jakub,
does it really want to execute?

Comment 9 Jakub Filak 2016-05-06 06:41:12 UTC
(In reply to Miroslav Grepl from comment #8)
> Jakub,
> does it really want to execute?

No, it does not. abrt-dump-journal-xorg tests whether the '/usr/bin/Xorg' path is has executable mode bit:
https://github.com/abrt/abrt/blob/master/src/plugins/xorg-utils.c#L106

<snip>
        if (access("/usr/bin/Xorg", X_OK) == 0)
            crash_info->exe = xstrdup("/usr/bin/Xorg");
        else
            crash_info->exe = xstrdup("/usr/bin/X");
</snip>

The tool tries to guess the path because Xorg back-traces found in syslog does not have any information about which program generated them and ABRT needs the path to get rpm package details and so on.

Comment 10 Miroslav Grepl 2016-05-06 09:08:41 UTC
Ok it makes sense.

Thank you.

Comment 11 Fedora Admin XMLRPC Client 2016-09-27 14:54:22 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 12 Fedora End Of Life 2016-11-24 13:42:41 UTC
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. 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 EOL if it remains open with a Fedora  'version'
of '23'.

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.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 23 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 this bug is closed as described in the policy above.

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 13 Fedora End Of Life 2016-12-20 16:15:22 UTC
Fedora 23 changed to end-of-life (EOL) status on 2016-12-20. Fedora 23 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. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

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