Bug 366461 - RHEL5 | SELinux: SELinux is preventing /usr/sbin/sendmail.sendmail (system_mail_t) "create"
RHEL5 | SELinux: SELinux is preventing /usr/sbin/sendmail.sendmail (system_m...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: selinux-policy (Show other bugs)
5.0
All Linux
low Severity high
: ---
: ---
Assigned To: Daniel Walsh
: OtherQA
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-11-05 03:36 EST by manoj
Modified: 2009-07-20 05:59 EDT (History)
3 users (show)

See Also:
Fixed In Version: RHBA-2008-0465
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-05-21 12:06:02 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 manoj 2007-11-05 03:36:55 EST
Method:

1. Enable SELinux in Enforcing mode on RHEL5 system.
2. I configured twiki application(apache)
3. Browse the wiki page. Click on Registration link and register a user on
the twiki home page.Once you enter the account details click on Submit key. The
account activation code will be mailed to email id entered while configuring
wiki account.
5. Enter the activation code(which was mailed) on the wiki site and click on
Submit.

Result: SELinux alert is generated.

Summary
    SELinux is preventing /usr/sbin/sendmail.sendmail (system_mail_t) "create"
    to <Unknown> (system_mail_t).

Detailed Description
    SELinux denied access requested by /usr/sbin/sendmail.sendmail. It is not
    expected that this access is required by /usr/sbin/sendmail.sendmail 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
    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 http://bugzilla.redhat.com/bugzilla/enter_bug.cgi
    against this package.

Additional Information        

Source Context                root:system_r:system_mail_t
Target Context                root:system_r:system_mail_t
Target Objects                None [ netlink_route_socket ]
Affected RPM Packages         sendmail-8.13.8-2.el5 [application]
Policy RPM                    selinux-policy-2.4.6-30.el5
Selinux Enabled               True
Policy Type                   targeted
MLS Enabled                   True
Enforcing Mode                Enforcing
Plugin Name                   plugins.catchall
Host Name                     rhel5.shankar.com
Platform                      Linux rhel5.shankar.com 2.6.18-8.el5 #1 SMP Fri
                              Jan 26 14:15:21 EST 2007 i686 i686
Alert Count                   1
Line Numbers                  

Raw Audit Messages            

avc: denied { create } for comm="sendmail" egid=51 euid=48
exe="/usr/sbin/sendmail.sendmail" exit=-13 fsgid=51 fsuid=48 gid=48 items=0
pid=11537 scontext=root:system_r:system_mail_t:s0 sgid=51
subj=root:system_r:system_mail_t:s0 suid=48 tclass=netlink_route_socket
tcontext=root:system_r:system_mail_t:s0 tty=(none) uid=48


Summary
    SELinux is preventing /usr/sbin/sendmail.sendmail (system_mail_t) "getattr"
    to /var/run/winbindd (winbind_var_run_t).

Detailed Description
    SELinux denied access requested by /usr/sbin/sendmail.sendmail. It is not
    expected that this access is required by /usr/sbin/sendmail.sendmail 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
    Sometimes labeling problems can cause SELinux denials.  You could try to
    restore the default system file context for /var/run/winbindd, restorecon -v
    /var/run/winbindd If this does not work, there is currently no automatic way
    to allow this access. Instead,  you can generate a local policy module to
    allow this access - see 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
    http://bugzilla.redhat.com/bugzilla/enter_bug.cgi against this package.

Additional Information        

Source Context                root:system_r:system_mail_t
Target Context                system_u:object_r:winbind_var_run_t
Target Objects                /var/run/winbindd [ dir ]
Affected RPM Packages         sendmail-8.13.8-2.el5 [application]samba-
                              common-3.0.23c-2 [target]
Policy RPM                    selinux-policy-2.4.6-30.el5
Selinux Enabled               True
Policy Type                   targeted
MLS Enabled                   True
Enforcing Mode                Enforcing
Plugin Name                   plugins.catchall_file
Host Name                     rhel5.shankar.com
Platform                      Linux rhel5.shankar.com 2.6.18-8.el5 #1 SMP Fri
                              Jan 26 14:15:21 EST 2007 i686 i686
Alert Count                   1
Line Numbers                  

Raw Audit Messages            

avc: denied { getattr } for comm="sendmail" dev=hda1 egid=51 euid=48
exe="/usr/sbin/sendmail.sendmail" exit=-13 fsgid=51 fsuid=48 gid=48 items=0
name="winbindd" path="/var/run/winbindd" pid=11537
scontext=root:system_r:system_mail_t:s0 sgid=51
subj=root:system_r:system_mail_t:s0 suid=48 tclass=dir
tcontext=system_u:object_r:winbind_var_run_t:s0 tty=(none) uid=48
Comment 1 Daniel Walsh 2007-11-05 11:57:57 EST
Please install U1 policy and make sure it fixes your problem.

Preview available on 

http://people.redhat.com/dwalsh/SELinux/RHEL5/noarch
Fixed in selinux-policy-2.4.6-106.el5
Comment 2 manoj 2007-11-06 01:45:02 EST
I could reproduce the bug with SELinux policy-2.4.6-106.el5 as well.
Comment 3 Daniel Walsh 2007-11-06 10:40:48 EST
Ok, did the email get sent?
Comment 4 Daniel Walsh 2007-11-06 10:47:34 EST
Ok, I will add this policy to the u2 update.

Fixed in selinux-policy-2.4.6-107.el5.src.rpm
Comment 5 RHEL Product and Program Management 2007-11-06 10:54:38 EST
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.
Comment 6 manoj 2007-11-06 22:38:57 EST
yes the mail was sent and recieved successfully.
Comment 7 Jay Turner 2007-11-30 02:35:17 EST
QE ack for RHEL5.2.  Reproducer in comment 0.
Comment 9 Eduard Benes 2008-04-14 09:10:52 EDT
Policy preview available on:

  http://people.redhat.com/dwalsh/SELinux/RHEL5/noarch
Comment 12 errata-xmlrpc 2008-05-21 12:06:02 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2008-0465.html

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