Bug 966142

Summary: SELinux policy blocking postfix
Product: [Fedora] Fedora Reporter: Matthieu Saulnier <casper>
Component: selinux-policy-targetedAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED ERRATA QA Contact: Ben Levenson <benl>
Severity: high Docs Contact:
Priority: unspecified    
Version: 18CC: dwalsh
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-05-23 07:59:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Matthieu Saulnier 2013-05-22 15:01:01 UTC
Description of problem:

With the actual version of selinux-policy package, SELinux policy doesn't allow to postfix some permissions that is fatal to him.


type=AVC msg=audit(1369179605.978:13184): avc:  denied  { read write } for  pid=7301 comm="smtpd" name="inet.smtp" dev="dm-0" ino=2360247 scontext=system_u:system_r:postf
ix_smtpd_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file

type=AVC msg=audit(1369223492.655:16957): avc:  denied  { open } for  pid=22620 comm="smtpd" path="/var/spool/postfix/pid/inet.smtp" dev="dm-0" ino=2360247 scontext=system_u:system_r:postfix_smtpd_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file

type=AVC msg=audit(1369226379.758:17200): avc:  denied  { getattr } for  pid=25171 comm="smtpd" path="/var/spool/postfix/pid/inet.smtp" dev="dm-0" ino=2360247 scontext=system_u:system_r:postfix_smtpd_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file

type=AVC msg=audit(1369228480.133:213): avc:  denied  { lock } for  pid=2687 comm="smtpd" path="/var/spool/postfix/pid/inet.smtp" dev="dm-0" ino=2360247 scontext=system_u:system_r:postfix_smtpd_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file



type=AVC msg=audit(1369210671.648:15812): avc:  denied  { read write } for  pid=15929 comm="cleanup" name="unix.cleanup" dev="dm-0" ino=2361869 scontext=system_u:system_r:postfix_cleanup_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file



type=AVC msg=audit(1369224556.297:17058): avc:  denied  { read write } for  pid=23689 comm="local" name="unix.local" dev="dm-0" ino=2361871 scontext=system_u:system_r:postfix_local_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file

type=AVC msg=audit(1369225347.369:17127): avc:  denied  { open } for  pid=24197 comm="local" path="/var/spool/postfix/pid/unix.local" dev="dm-0" ino=2361871 scontext=system_u:system_r:postfix_local_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file

type=AVC msg=audit(1369225506.039:17148): avc:  denied  { getattr } for  pid=24460 comm="local" path="/var/spool/postfix/pid/unix.local" dev="dm-0" ino=2361871 scontext=system_u:system_r:postfix_local_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file

type=AVC msg=audit(1369225601.475:17154): avc:  denied  { lock } for  pid=24581 comm="local" path="/var/spool/postfix/pid/unix.local" dev="dm-0" ino=2361871 scontext=system_u:system_r:postfix_local_t:s0 tcontext=system_u:object_r:postfix_var_run_t:s0 tclass=file


Version-Release number of selected component (if applicable):
selinux-policy-targeted-3.11.1-95.fc18.noarch


How reproducible:
Always


Steps to Reproduce:
1. Update f18 server running postfix
2.
3.


Actual results:
Postfix is broken


Expected results:
Postfix works fine with the actual SELinux policy


Additional info:
First I've done a mass-restorecon (with 'touch /.autorelabel;reboot'), but postfix got the same fatal errors in /var/log/maillog.
I made 3 modules policy for AVC comm="smtpd", comm="cleanup" and comm="local", and postfix works fine then.

Comment 1 Miroslav Grepl 2013-05-23 07:59:24 UTC
Has been fixed in selinux-policy-3.11.1-96.fc18 and the update is now going to the stable.