Bug 1529830

Summary: SELinux is preventing mpd from using the 'execstack' accesses on a process.
Product: [Fedora] Fedora Reporter: bugzilla
Component: selinux-policyAssignee: Lukas Vrabec <lvrabec>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 27CC: dwalsh, lvrabec, mgrepl, plautrba, pmoore
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:22dbe3c4d6aa4b19d80b0a2f0bd39357727c3b7392121b37921c9cf07a9001e0;VARIANT_ID=workstation;
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-02-19 11:51:03 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 bugzilla 2017-12-30 02:43:51 UTC
Description of problem:
This error occurs when mpd starts with systemctl
SELinux is preventing mpd from using the 'execstack' accesses on a process.

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

If you believe that mpd should be allowed execstack access on processes labeled mpd_t 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:
# ausearch -c 'mpd' --raw | audit2allow -M my-mpd
# semodule -X 300 -i my-mpd.pp

Additional Information:
Source Context                system_u:system_r:mpd_t:s0
Target Context                system_u:system_r:mpd_t:s0
Target Objects                Unknown [ process ]
Source                        mpd
Source Path                   mpd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-158.14.fc23.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.4.7-300.fc23.x86_64 #1 SMP Wed
                              Apr 13 02:52:52 UTC 2016 x86_64 x86_64
Alert Count                   2
First Seen                    2016-04-20 06:46:44 EDT
Last Seen                     2016-04-24 19:17:37 EDT
Local ID                      dcc1ce6b-310b-4e19-91a9-31ef40d7e275

Raw Audit Messages
type=AVC msg=audit(1461539857.928:242): avc:  denied  { execstack } for  pid=1014 comm="mpd" scontext=system_u:system_r:mpd_t:s0 tcontext=system_u:system_r:mpd_t:s0 tclass=process permissive=0


Hash: mpd,mpd_t,mpd_t,process,execstack

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

Additional info:
component:      selinux-policy
reporter:       libreport-2.9.3
hashmarkername: setroubleshoot
kernel:         4.14.8-300.fc27.x86_64
type:           libreport

Comment 1 Lukas Vrabec 2018-02-19 11:51:03 UTC
Hi, 

mpd is trying to make main stack executable, which is from security POV dangerous operation. This is bug in mpd code. Closing as WONTFIX.