Bug 915819 - SELinux is preventing /usr/sbin/collectd from using the net_raw capability.
Summary: SELinux is preventing /usr/sbin/collectd from using the net_raw capability.
Keywords:
Status: CLOSED DUPLICATE of bug 915771
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 17
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-26 15:13 UTC by Joel Uckelman
Modified: 2013-02-28 15:18 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-02-28 15:18:39 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Joel Uckelman 2013-02-26 15:13:00 UTC
Description of problem:

SELinux is preventing /usr/sbin/collectd from using the net_raw capability.

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

If you believe that collectd should have the net_raw 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 collectd /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp


Additional Information:
Source Context                system_u:system_r:collectd_t:s0
Target Context                system_u:system_r:collectd_t:s0
Target Objects                 [ capability ]
Source                        collectd
Source Path                   /usr/sbin/collectd
Port                          <Unknown>
Host                          clio
Source RPM Packages           collectd-4.10.8-2.fc17.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.10.0-167.fc17.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     clio
Platform                      Linux clio 3.7.9-101.fc17.x86_64 #1 SMP Mon Feb 18
                              22:04:06 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-02-26 16:09:13 CET
Last Seen                     2013-02-26 16:09:13 CET
Local ID                      798183c6-8bab-4090-9b83-bf0291d757f9

Raw Audit Messages
type=AVC msg=audit(1361891353.175:11764): avc:  denied  { net_raw } for  pid=18000 comm="collectd" capability=13  scontext=system_u:system_r:collectd_t:s0 tcontext=system_u:system_r:collectd_t:s0 tclass=capability


type=SYSCALL msg=audit(1361891353.175:11764): arch=x86_64 syscall=socket success=no exit=EPERM a0=11 a1=2 a2=300 a3=7f9ced8cf910 items=0 ppid=1 pid=18000 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=4294967295 tty=(none) comm=collectd exe=/usr/sbin/collectd subj=system_u:system_r:collectd_t:s0 key=(null)

Hash: collectd,collectd_t,collectd_t,capability,net_raw

audit2allow

#============= collectd_t ==============
allow collectd_t self:capability net_raw;

audit2allow -R

#============= collectd_t ==============
allow collectd_t self:capability net_raw;


How reproducible:

Always

Steps to Reproduce:
1. Enable the collectd dns plugin.
  
Actual results:

SELinux denial

Expected results:

No denial

Comment 1 Daniel Walsh 2013-02-28 14:34:57 UTC
Does collectd modify the network settings?

Comment 2 Miroslav Grepl 2013-02-28 15:18:39 UTC

*** This bug has been marked as a duplicate of bug 915771 ***


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