Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 970076 - SELinux is preventing /usr/bin/python2.7 from 'unlink' accesses on the file hplip_config_usb_printer.log.
SELinux is preventing /usr/bin/python2.7 from 'unlink' accesses on the file h...
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-06-03 08:30 EDT by Antonio Guzmán Simón
Modified: 2013-06-04 09:56 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-06-04 09:56:17 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Antonio Guzmán Simón 2013-06-03 08:30:43 EDT
Description of problem:
SELinux is preventing /usr/bin/python2.7 from 'unlink' accesses on the file hplip_config_usb_printer.log.

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

If cree que de manera predeterminada, python2.7 debería permitir acceso unlink sobre  hplip_config_usb_printer.log file.     
Then debería reportar esto como un error.
Puede generar un módulo de política local para permitir este acceso.
permita el acceso momentáneamente executando:
# grep hp-config_usb_p /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:object_r:var_log_t:s0
Target Objects                hplip_config_usb_printer.log [ file ]
Source                        hp-config_usb_p
Source Path                   /usr/bin/python2.7
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           python-2.7.3-13.fc18.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.11.1-97.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.9.4-200.fc18.x86_64 #1 SMP Fri
                              May 24 20:10:49 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-06-03 14:25:19 CEST
Last Seen                     2013-06-03 14:25:19 CEST
Local ID                      bfc3f04c-cc0d-44b1-a4d2-6e584dce3ae7

Raw Audit Messages
type=AVC msg=audit(1370262319.769:2005): avc:  denied  { unlink } for  pid=10827 comm="hp-config_usb_p" name="hplip_config_usb_printer.log" dev="dm-1" ino=2496465 scontext=system_u:system_r:cupsd_t:s0-s0:c0.c1023 tcontext=system_u:object_r:var_log_t:s0 tclass=file

type=SYSCALL msg=audit(1370262319.769:2005): arch=x86_64 syscall=unlink success=no exit=EACCES a0=1285e70 a1=1 a2=353d9b3a08 a3=7265746e6972705f items=0 ppid=1 pid=10827 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=4294967295 tty=(none) comm=hp-config_usb_p exe=/usr/bin/python2.7 subj=system_u:system_r:cupsd_t:s0-s0:c0.c1023 key=(null)

Hash: hp-config_usb_p,cupsd_t,var_log_t,file,unlink


#============= cupsd_t ==============
allow cupsd_t var_log_t:file unlink;

audit2allow -R
require {
	type cupsd_t;

#============= cupsd_t ==============

Additional info:
reporter:       libreport-2.1.4
hashmarkername: setroubleshoot
kernel:         3.9.4-200.fc18.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2013-06-04 09:56:17 EDT

# restorecon -R -v /var/log/hp

fix it?

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