Bug 864219 - SELinux is preventing /usr/bin/python2.7 from using the 'sys_nice' capabilities.
SELinux is preventing /usr/bin/python2.7 from using the 'sys_nice' capabilities.
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
18
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:2dab6161165242067641680c7b3...
:
: 864218 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-08 18:08 EDT by Flóki Pálsson
Modified: 2012-12-11 12:39 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-12-10 16:39:05 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
File: type (9 bytes, text/plain)
2012-10-08 18:08 EDT, Flóki Pálsson
no flags Details
File: hashmarkername (14 bytes, text/plain)
2012-10-08 18:08 EDT, Flóki Pálsson
no flags Details

  None (edit)
Description Flóki Pálsson 2012-10-08 18:08:12 EDT
Description of problem:
starting s-c-samba

Additional info:
libreport version: 2.0.15
kernel:         3.6.0-3.fc18.x86_64

description:
:SELinux is preventing /usr/bin/python2.7 from using the 'sys_nice' capabilities.
:
:*****  Plugin catchall (100. confidence) suggests  ***************************
:
:If you believe that python2.7 should have the sys_nice capability 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 system-config-s /var/log/audit/audit.log | audit2allow -M mypol
:# semodule -i mypol.pp
:
:Additional Information:
:Source Context                system_u:system_r:sambagui_t:s0-s0:c0.c1023
:Target Context                system_u:system_r:sambagui_t:s0-s0:c0.c1023
:Target Objects                 [ capability ]
:Source                        system-config-s
: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-32.fc18.noarch
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Enforcing
:Host Name                     (removed)
:Platform                      Linux (removed) 3.6.0-3.fc18.x86_64 #1 SMP Wed Oct
:                              3 13:29:15 UTC 2012 x86_64 x86_64
:Alert Count                   1
:First Seen                    2012-10-08 22:03:43 GMT
:Last Seen                     2012-10-08 22:03:43 GMT
:Local ID                      00ec4269-027f-43ac-b0b9-b417137ce30f
:
:Raw Audit Messages
:type=AVC msg=audit(1349733823.908:236): avc:  denied  { sys_nice } for  pid=18917 comm="system-config-s" capability=23  scontext=system_u:system_r:sambagui_t:s0-s0:c0.c1023 tcontext=system_u:system_r:sambagui_t:s0-s0:c0.c1023 tclass=capability
:
:
:type=AVC msg=audit(1349733823.908:236): avc:  denied  { setsched } for  pid=18917 comm="system-config-s" scontext=system_u:system_r:sambagui_t:s0-s0:c0.c1023 tcontext=system_u:system_r:sambagui_t:s0-s0:c0.c1023 tclass=process
:
:
:type=SYSCALL msg=audit(1349733823.908:236): arch=x86_64 syscall=sched_setscheduler success=no exit=EACCES a0=49e5 a1=0 a2=7fff91de82e0 a3=1 items=0 ppid=18916 pid=18917 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=system-config-s exe=/usr/bin/python2.7 subj=system_u:system_r:sambagui_t:s0-s0:c0.c1023 key=(null)
:
:Hash: system-config-s,sambagui_t,sambagui_t,capability,sys_nice
:
:audit2allow
:
:#============= sambagui_t ==============
:allow sambagui_t self:capability sys_nice;
:allow sambagui_t self:process setsched;
:
:audit2allow -R
:
:#============= sambagui_t ==============
:allow sambagui_t self:capability sys_nice;
:allow sambagui_t self:process setsched;
:
Comment 1 Flóki Pálsson 2012-10-08 18:08:15 EDT
Created attachment 623767 [details]
File: type
Comment 2 Flóki Pálsson 2012-10-08 18:08:17 EDT
Created attachment 623768 [details]
File: hashmarkername
Comment 3 Miroslav Grepl 2012-10-09 04:23:56 EDT
*** Bug 864218 has been marked as a duplicate of this bug. ***
Comment 4 Miroslav Grepl 2012-10-09 05:09:52 EDT
Fixed in selinux-policy-3.11.1-34.fc18.noarch
Comment 5 Flóki Pálsson 2012-10-13 08:32:57 EDT
ok now
Comment 6 Fedora Update System 2012-10-23 16:33:48 EDT
selinux-policy-3.11.1-43.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/selinux-policy-3.11.1-43.fc18
Comment 7 BLS 2012-10-23 19:11:19 EDT
Installed latest Samba to share files between my Windows 7 box.

Installed system-config-samba
Opened system-config-samba and go the error from SELinux; seems python2.7 need read access to the /var/tmp directory.

Said i should submit bug report so I did for the community.


Package: (null)
OS Release: Fedora release 17 (Beefy Miracle)
Comment 8 BLS 2012-10-23 19:25:59 EDT
Installed latest Samba version to share files between Fedora and my Windows box.

Installed system-config-samba
opened system-config-samba

Got the error notice from SELinux and manually enabled the 'sys_nice' function from the output from SELinux troubleshooter.

Not sure if python 2.7 should have access to this function or not but only popped up when I opened system-config-samba (GUI for Samba)


Package: (null)
OS Release: Fedora release 17 (Beefy Miracle)
Comment 9 Fedora Update System 2012-10-26 11:36:44 EDT
selinux-policy-3.11.1-46.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/selinux-policy-3.11.1-46.fc18
Comment 10 Fedora Update System 2012-10-26 15:25:56 EDT
Package selinux-policy-3.11.1-46.fc18:
* should fix your issue,
* was pushed to the Fedora 18 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.11.1-46.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-16862/selinux-policy-3.11.1-46.fc18
then log in and leave karma (feedback).
Comment 11 Flóki Pálsson 2012-10-30 19:48:54 EDT
starting s-c-samba

Package: (null)
OS Release: Fedora release 17 (Beefy Miracle)

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