Bug 1215308

Summary: SELinux is preventing /usr/sbin/clamd from using the 'fsetid' capabilities.
Product: [Fedora] Fedora Reporter: JokeDude <enricop>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: dominick.grift, dwalsh, lvrabec, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:52bbb59b3d4b1541e04b33e07e8b4259e45dae54540e8868d925878cdfe8447f
Fixed In Version: selinux-policy-3.13.1-105.19.fc21 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-14 15:50:41 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 JokeDude 2015-04-25 07:14:48 UTC
Description of problem:
Installed clamd.
Reboot
SELinux is preventing /usr/sbin/clamd from using the 'fsetid' capabilities.

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

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

Additional Information:
Source Context                system_u:system_r:antivirus_t:s0
Target Context                system_u:system_r:antivirus_t:s0
Target Objects                Unknown [ capability ]
Source                        clamd
Source Path                   /usr/sbin/clamd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           clamav-server-0.98.6-1.fc21.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-105.13.fc21.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.19.4-200.fc21.x86_64 #1 SMP Mon
                              Apr 13 21:43:26 UTC 2015 x86_64 x86_64
Alert Count                   2
First Seen                    2015-04-24 10:05:31 SAST
Last Seen                     2015-04-25 09:13:17 SAST
Local ID                      6771d74a-c405-41f3-a495-a8ce26d07c9f

Raw Audit Messages
type=AVC msg=audit(1429945997.390:421): avc:  denied  { fsetid } for  pid=1074 comm="clamd" capability=4  scontext=system_u:system_r:antivirus_t:s0 tcontext=system_u:system_r:antivirus_t:s0 tclass=capability permissive=0


type=AVC msg=audit(1429945997.390:421): avc:  denied  { fsetid } for  pid=1074 comm="clamd" capability=4  scontext=system_u:system_r:antivirus_t:s0 tcontext=system_u:system_r:antivirus_t:s0 tclass=capability permissive=0


type=SYSCALL msg=audit(1429945997.390:421): arch=x86_64 syscall=chmod success=yes exit=0 a0=1ca11c0 a1=1b6 a2=b a3=1ca1214 items=0 ppid=1066 pid=1074 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=clamd exe=/usr/sbin/clamd subj=system_u:system_r:antivirus_t:s0 key=(null)

Hash: clamd,antivirus_t,antivirus_t,capability,fsetid

Version-Release number of selected component:
selinux-policy-3.13.1-105.13.fc21.noarch

Additional info:
reporter:       libreport-2.3.0
hashmarkername: setroubleshoot
kernel:         3.19.4-200.fc21.x86_64
type:           libreport

Comment 1 Miroslav Grepl 2015-05-12 08:34:34 UTC
commit 8b25816d5a823feac84f591add7c3c056188544d
Author: Miroslav Grepl <mgrepl>
Date:   Tue May 12 10:33:21 2015 +0200

    Clamd needs to have fsetid capability. BZ(1215308)

Comment 2 Fedora Update System 2015-06-24 12:29:00 UTC
selinux-policy-3.13.1-105.18.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/selinux-policy-3.13.1-105.18.fc21

Comment 3 Fedora Update System 2015-06-25 08:22:39 UTC
Package selinux-policy-3.13.1-105.18.fc21:
* should fix your issue,
* was pushed to the Fedora 21 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.13.1-105.18.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-10708/selinux-policy-3.13.1-105.18.fc21
then log in and leave karma (feedback).

Comment 4 Fedora Update System 2015-06-30 07:31:28 UTC
selinux-policy-3.13.1-105.19.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/selinux-policy-3.13.1-105.19.fc21

Comment 5 Fedora Update System 2015-07-14 15:50:41 UTC
selinux-policy-3.13.1-105.19.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.