Bug 595528 - SELinux is preventing /usr/sbin/clamd "create" access on clamd.sock.
SELinux is preventing /usr/sbin/clamd "create" access on clamd.sock.
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
13
x86_64 Linux
low Severity medium
: ---
: ---
Assigned To: Daniel Walsh
Fedora Extras Quality Assurance
setroubleshoot_trace_hash:c5e0bbd5fa9...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-05-24 17:42 EDT by Adam Royal
Modified: 2010-07-01 13:27 EDT (History)
3 users (show)

See Also:
Fixed In Version: selinux-policy-3.7.19-23.fc13
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-06-08 15:28:10 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Adam Royal 2010-05-24 17:42:30 EDT
Summary:

SELinux is preventing /usr/sbin/clamd "create" access on clamd.sock.

Detailed Description:

SELinux denied access requested by clamd. It is not expected that this access is
required by clamd and this access may signal an intrusion attempt. It is also
possible that the specific version or configuration of the application is
causing it to require additional access.

Allowing Access:

You can generate a local policy module to allow this access - see FAQ
(http://docs.fedoraproject.org/selinux-faq-fc5/#id2961385) Please file a bug
report.

Additional Information:

Source Context                unconfined_u:system_r:clamd_t:s0
Target Context                unconfined_u:object_r:var_run_t:s0
Target Objects                clamd.sock [ sock_file ]
Source                        clamd
Source Path                   /usr/sbin/clamd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           clamav-server-0.95.3-1301.fc13
Target RPM Packages           
Policy RPM                    selinux-policy-3.7.19-15.fc13
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux (removed) 2.6.33.4-95.fc13.x86_64 #1 SMP
                              Thu May 13 05:16:23 UTC 2010 x86_64 x86_64
Alert Count                   1
First Seen                    Mon 24 May 2010 05:41:32 PM EDT
Last Seen                     Mon 24 May 2010 05:41:32 PM EDT
Local ID                      4c0a30d7-9ae2-4f33-b8e1-60c5a79f3beb
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1274737292.323:525): avc:  denied  { create } for  pid=24508 comm="clamd" name="clamd.sock" scontext=unconfined_u:system_r:clamd_t:s0 tcontext=unconfined_u:object_r:var_run_t:s0 tclass=sock_file

node=(removed) type=SYSCALL msg=audit(1274737292.323:525): arch=c000003e syscall=49 success=no exit=-13 a0=4 a1=7fffdafca6c0 a2=6e a3=7fffdafca3b0 items=0 ppid=24505 pid=24508 auid=500 uid=486 gid=470 euid=486 suid=486 fsuid=486 egid=470 sgid=470 fsgid=470 tty=(none) ses=1 comm="clamd" exe="/usr/sbin/clamd" subj=unconfined_u:system_r:clamd_t:s0 key=(null)



Hash String generated from  catchall,clamd,clamd_t,var_run_t,sock_file,create
audit2allow suggests:

#============= clamd_t ==============
allow clamd_t var_run_t:sock_file create;
Comment 1 Daniel Walsh 2010-05-25 11:19:13 EDT
This could be a labeling issue.

Could you execute 

restorecon -R -v /var/run 

And see if this fixes the problem.
Comment 2 Adam Royal 2010-05-25 16:04:13 EDT
That did not fix the problem. The same message was reported.
Comment 3 Daniel Walsh 2010-05-27 14:59:13 EDT
You can add these rules for now using

# grep avc /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Fixed in selinux-policy-3.7.19-22.fc13.noarch

Or you can move the socket into /var/run/clamav
Comment 4 Fedora Update System 2010-05-28 08:27:57 EDT
selinux-policy-3.7.19-22.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/selinux-policy-3.7.19-22.fc13
Comment 5 Fedora Update System 2010-05-31 14:20:00 EDT
selinux-policy-3.7.19-22.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update selinux-policy'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/selinux-policy-3.7.19-22.fc13
Comment 6 Fedora Update System 2010-06-02 14:12:05 EDT
selinux-policy-3.7.19-23.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update selinux-policy'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/selinux-policy-3.7.19-23.fc13
Comment 7 Fedora Update System 2010-06-08 15:26:29 EDT
selinux-policy-3.7.19-23.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.

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