Bug 1294592

Summary: SELinux is preventing brprintconflsr3 from using the 'execmem' access on a process.
Product: [Fedora] Fedora Reporter: Christopher Archer <chrisa>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 23CC: ambijat, bugzilla, chrisa, dominick.grift, dwalsh, extras-qa, fredred, lvrabec, mgrepl, m.koshelev, pebolle, plautrba
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: abrt_hash:22b3dd6db8d10b90893b3aa887ed08093003d09faf341a90188e264986a37c7d
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1246184 Environment:
Last Closed: 2016-01-21 11:37:44 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 Christopher Archer 2015-12-29 06:28:56 UTC
+++ This bug was initially created as a clone of Bug #1246184 +++

Description of problem:
When trying to print, the print job is not sent to the printer. SELinux is blocking it. The driver used is from the Brother website and has worked well for the last few years. Problems seemed to have started in Fedora 22 and were temporarily fixed, but now back in fully updated Fedora 23.

SELinux is preventing brprintconflsr3 from using the execmem access on a process.

*****  Plugin catchall_boolean (89.3 confidence) suggests   ******************

If you want to allow cups to execmem
Then you must tell SELinux about this by enabling the 'cups_execmem' boolean.
You can read 'None' man page for more details.
Do
setsebool -P cups_execmem 1

*****  Plugin catchall (11.6 confidence) suggests   **************************

If you believe that brprintconflsr3 should be allowed execmem access on processes labeled cupsd_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:
# grep brprintconflsr3 /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:cupsd_t:s0-s0:c0.c1023
Target Context                system_u:system_r:cupsd_t:s0-s0:c0.c1023
Target Objects                Unknown [ process ]
Source                        brprintconflsr3
Source Path                   brprintconflsr3
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-158.fc23.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.2.8-300.fc23.x86_64 #1 SMP Tue Dec 15
                              16:49:06 UTC 2015 x86_64 x86_64
Alert Count                   10
First Seen                    2015-12-29 01:04:30 EST
Last Seen                     2015-12-29 01:04:30 EST
Local ID                      bb9692a3-b119-4cb5-9181-76d8be4b20df

Raw Audit Messages
type=AVC msg=audit(1451369070.392:860): avc:  denied  { execmem } for  pid=4917 comm="rawtobr3" scontext=system_u:system_r:cupsd_t:s0-s0:c0.c1023 tcontext=system_u:system_r:cupsd_t:s0-s0:c0.c1023 tclass=process permissive=0


Hash: brprintconflsr3,cupsd_t,cupsd_t,process,execmem

Comment 1 bugzilla 2016-01-12 16:25:50 UTC
Description of problem:
I attempted to print from Chrome. Nothing printed, despite normal behavior of Chrome and the list of print jobs window. An SELinux alert appeared. Following the instructions for generating a local policy to allow this access resolved the issue.


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

Comment 2 Miroslav Grepl 2016-01-21 11:37:44 UTC
*****  Plugin catchall_boolean (89.3 confidence) suggests   ******************

If you want to allow cups to execmem
Then you must tell SELinux about this by enabling the 'cups_execmem' boolean.
You can read 'None' man page for more details.
Do
setsebool -P cups_execmem 1