Bug 482971 - SELinux is preventing spamassassin (spamc_t) "write" postfix_local_t
Summary: SELinux is preventing spamassassin (spamc_t) "write" postfix_local_t
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 10
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-01-29 04:10 UTC by Kevin Jones
Modified: 2009-11-18 11:19 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-11-18 11:19:28 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Kevin Jones 2009-01-29 04:10:53 UTC
I use postfix and have a systemwide /etc/procmailrc that sends email through spamassassin. When this occurs it generates the selinux error at the end of this message. I went into the boolean sections and checked both spamassassin entries but that did not seem to help. 

Here is the /etc/procmailrc. There are no user defined .procmailrc files.
:0fw spamassassin.lock
* < 256000
| usr/bin/spamassassin

I'm not sure if I need to reconfigure something or if selinux is just being overly paranoid? Spamassassin people thought spamassassin wasn't behaving abnormally and suggested I post an selinux bugreport.


SELinux is preventing spamassassin (spamc_t) "write" postfix_local_t.

Detailed Description:

SELinux denied access requested by spamassassin. It is not expected that this
access is required by spamassassin 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://fedora.redhat.com/docs/selinux-faq-fc5/#id2961385) Or you can disable
SELinux protection altogether. Disabling SELinux protection is not recommended.
Please file a bug report (http://bugzilla.redhat.com/bugzilla/enter_bug.cgi)
against this package.

Additional Information:

Source Context                unconfined_u:system_r:spamc_t:s0
Target Context                unconfined_u:system_r:postfix_local_t:s0
Target Objects                pipe [ fifo_file ]
Source                        spamassassin
Source Path                   /usr/bin/perl
Port                          <Unknown>
Host                          wild-missouri.dyndns.org
Source RPM Packages           perl-5.10.0-53.fc10
Target RPM Packages           
Policy RPM                    selinux-policy-3.5.13-40.fc10
Selinux Enabled               True
Policy Type                   targeted
MLS Enabled                   True
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     wild-missouri.dyndns.org
Platform                      Linux wild-missouri.dyndns.org
                              2.6.27.12-170.2.5.fc10.i686 #1 SMP Wed Jan 21
                              02:09:37 EST 2009 i686 i686
Alert Count                   7
First Seen                    Sat 24 Jan 2009 10:42:44 PM EST
Last Seen                     Tue 27 Jan 2009 12:39:58 PM EST
Local ID                      1757aec7-125c-471c-81af-64bc96349033
Line Numbers                  

Raw Audit Messages            

node=wild-missouri.dyndns.org type=AVC msg=audit(1233077998.752:64): avc:  denied  { write } for  pid=3561 comm="spamassassin" path="pipe:[18009]" dev=pipefs ino=18009 scontext=unconfined_u:system_r:spamc_t:s0 tcontext=unconfined_u:system_r:postfix_local_t:s0 tclass=fifo_file

node=wild-missouri.dyndns.org type=SYSCALL msg=audit(1233077998.752:64): arch=40000003 syscall=11 success=yes exit=0 a0=964cdb8 a1=964c008 a2=964eba0 a3=1 items=0 ppid=3560 pid=3561 auid=4294967295 uid=500 gid=500 euid=500 suid=500 fsuid=500 egid=500 sgid=500 fsgid=500 tty=(none) ses=4294967295 comm="spamassassin" exe="/usr/bin/perl" subj=unconfined_u:system_r:spamc_t:s0 key=(null)

Comment 1 Kevin Jones 2009-01-30 02:52:37 UTC
Just to see if it would make any difference, I loaded spamd and tried putting spamc -L into procmailrc but I still received the selinux error (see below)


Summary:

SELinux is preventing spamc (spamc_t) "write" postfix_local_t.

Detailed Description:

SELinux denied access requested by spamc. It is not expected that this access is
required by spamc 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://fedora.redhat.com/docs/selinux-faq-fc5/#id2961385) Or you can disable
SELinux protection altogether. Disabling SELinux protection is not recommended.
Please file a bug report (http://bugzilla.redhat.com/bugzilla/enter_bug.cgi)
against this package.

Additional Information:

Source Context                system_u:system_r:spamc_t:s0
Target Context                system_u:system_r:postfix_local_t:s0
Target Objects                pipe [ fifo_file ]
Source                        spamc
Source Path                   /usr/bin/spamc
Port                          <Unknown>
Host                          wild-missouri.dyndns.org
Source RPM Packages           spamassassin-3.2.5-2.fc10
Target RPM Packages           
Policy RPM                    selinux-policy-3.5.13-40.fc10
Selinux Enabled               True
Policy Type                   targeted
MLS Enabled                   True
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     wild-missouri.dyndns.org
Platform                      Linux wild-missouri.dyndns.org
                              2.6.27.12-170.2.5.fc10.i686 #1 SMP Wed Jan 21
                              02:09:37 EST 2009 i686 i686
Alert Count                   1
First Seen                    Thu 29 Jan 2009 04:51:35 PM EST
Last Seen                     Thu 29 Jan 2009 04:51:35 PM EST
Local ID                      6c8588bd-f839-4abd-91c0-e1ce86541f32
Line Numbers                  

Raw Audit Messages            

node=wild-missouri.dyndns.org type=AVC msg=audit(1233265895.797:13): avc:  denied  { write } for  pid=2722 comm="spamc" path="pipe:[13047]" dev=pipefs ino=13047 scontext=system_u:system_r:spamc_t:s0 tcontext=system_u:system_r:postfix_local_t:s0 tclass=fifo_file

node=wild-missouri.dyndns.org type=SYSCALL msg=audit(1233265895.797:13): arch=40000003 syscall=11 success=yes exit=0 a0=9fb7db8 a1=9fb7008 a2=9fb9ba0 a3=2 items=0 ppid=2721 pid=2722 auid=4294967295 uid=500 gid=500 euid=500 suid=500 fsuid=500 egid=500 sgid=500 fsgid=500 tty=(none) ses=4294967295 comm="spamc" exe="/usr/bin/spamc" subj=system_u:system_r:spamc_t:s0 key=(null)

Comment 2 Miroslav Grepl 2009-01-30 13:02:26 UTC
Maybe I don't understand right. You see this SELinux message, but everything works fine ?

Comment 3 Daniel Walsh 2009-01-30 13:28:54 UTC
This looks like either a leaked file descriptor or a redirection of stdout/stderr.

I don't see a problem with allowing it, Looks like postfix processes are all using each others fifo_files.

Comment 4 Kevin Jones 2009-01-30 14:49:53 UTC
#2: Yes this is correct. I do get a Se Linux error with each email that comes in. However se linux does not interfere with the email as it comes through OK. There seems to be a long delay but I do not know if this is caused by selinux or just how long it takes spamassassin to scan a message. Also I wanted to make sure I had not been haxored as I am not an expert at linux administration and was worried I had created some security risk.

Comment 5 Daniel Walsh 2009-01-30 16:01:34 UTC
This does not indicate a hack.

Comment 6 Miroslav Grepl 2009-02-05 12:45:14 UTC
Fixed in selinux-policy-3.5.13-44.fc10

Comment 7 Bug Zapper 2009-11-18 10:54:14 UTC
This message is a reminder that Fedora 10 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 10.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '10'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 10's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 10 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping


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