Bug 430193

Summary: Enforce level prevents clamav-milter from running
Product: [Fedora] Fedora Reporter: David Highley <david.m.highley>
Component: selinux-policy-targetedAssignee: Daniel Walsh <dwalsh>
Status: CLOSED NOTABUG QA Contact: Ben Levenson <benl>
Severity: low Docs Contact:
Priority: low    
Version: 8   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-01-28 19:55:13 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 David Highley 2008-01-25 04:14:13 UTC
Description of problem:
When starting the service clamav-milter it attempts to access a file in the
directory /var/lib/clamav/daily.inc and gets blocked when in enforce mode.

Version-Release number of selected component (if applicable):
selinux-policy-targeted-3.0.8-76.fc8
clamav-milter-0.92-6.fc8

How reproducible:


Steps to Reproduce:
1.service clamav-milter start
2.
3.
  
Actual results:


Expected results:


Additional info:
Directory /var/lib/clamav/daily.inc is owned by clamav:clamav. The service
clamav-milter runs as clamilt:clamilt. So I'm not sure if this is a policy issue
or a package configuration issue.

Comment 1 Daniel Walsh 2008-01-25 14:49:54 UTC
What avc messages are you seeing in /var/log/audit/audit.log?

Comment 2 David Highley 2008-01-26 04:19:23 UTC
type=SYSCALL msg=audit(1201320796.020:711): arch=c000003e syscall=2 success=yes 
exit=7 a0=2aaaacf9f3c0 a1=90800 a2=35 a3=0 items=0 ppid=1 pid=4338 auid=0 uid=49
2 gid=486 euid=492 suid=492 fsuid=492 egid=486 sgid=486 fsgid=486 tty=(none) com
m="clamav-milter" exe="/usr/sbin/clamav-milter" subj=system_u:system_r:clamd_t:s
0 key=(null)
type=AVC msg=audit(1201320796.020:712): avc:  denied  { getattr } for  pid=4338
comm="clamav-milter" path="/var/lib/clamav/daily.inc" dev=dm-0 ino=27066426
scontext=system_u:system_r:clamd_t:s0 tcontext=system_u:object_r:user_home_t:s0
tclass=dir
type=SYSCALL msg=audit(1201320796.020:712): arch=c000003e syscall=5 success=yes
exit=0 a0=7 a1=409ffd40 a2=409ffd40 a3=0 items=0 ppid=1 pid=4338 auid=0 uid=492
gid=486 euid=492 suid=492 fsuid=492 egid=486 sgid=486 fsgid=486 tty=(none)
comm="clamav-milter" exe="/usr/sbin/clamav-milter"
subj=system_u:system_r:clamd_t:s0 key=(null)

Comment 3 David Highley 2008-01-26 04:22:20 UTC
Another related one:

type=AVC msg=audit(1201320754.665:705): avc:  denied  { getattr } for  pid=4338 
comm="clamav-milter" path="/var/lib/clamav/main.cvd" dev=dm-0 ino=27066444 scont
ext=system_u:system_r:clamd_t:s0 tcontext=system_u:object_r:user_home_t:s0 tclas
s=file

Comment 4 Daniel Walsh 2008-01-28 19:55:13 UTC
David please set bugs to assigned not modified.  modified means I am done with
them, and they will disappear from my view.


This looks again like a labeling problem. You have files under /var/lib that are
labeled like they are in a homedir.

restorecon -R -v -F /var/lib