Bug 996823 - SELinux is preventing /usr/sbin/sendmail.sendmail from 'getattr' accesses on the directory /etc/mail.
SELinux is preventing /usr/sbin/sendmail.sendmail from 'getattr' accesses on ...
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
19
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:cdff1f6c4d2de933127aa916eb2...
:
: 996824 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-08-14 00:02 EDT by Mikhail
Modified: 2013-08-14 08:27 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-08-14 08:27:11 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 Mikhail 2013-08-14 00:02:05 EDT
Description of problem:
SELinux is preventing /usr/sbin/sendmail.sendmail from 'getattr' accesses on the directory /etc/mail.

*****  Plugin httpd_can_sendmail (91.4 confidence) suggests  *****************

If you want to allow httpd to send mail
Then you must setup SELinux to allow this
Do
setsebool -P httpd_can_sendmail=1

*****  Plugin catchall (9.59 confidence) suggests  ***************************

If you believe that sendmail.sendmail should be allowed getattr access on the mail directory by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
Do
allow this access for now by executing:
# grep sendmail /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:httpd_t:s0
Target Context                system_u:object_r:etc_mail_t:s0
Target Objects                /etc/mail [ dir ]
Source                        sendmail
Source Path                   /usr/sbin/sendmail.sendmail
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           sendmail-8.14.7-1.fc19.x86_64
Target RPM Packages           sendmail-8.14.7-1.fc19.x86_64
Policy RPM                    selinux-policy-3.12.1-69.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.10.5-201.fc19.x86_64 #1 SMP Wed
                              Aug 7 16:25:24 UTC 2013 x86_64 x86_64
Alert Count                   2
First Seen                    2013-08-11 15:40:58 YEKT
Last Seen                     2013-08-11 15:41:58 YEKT
Local ID                      8d5f5061-34e5-497a-be06-1f3e23d2c2b9

Raw Audit Messages
type=AVC msg=audit(1376214118.953:640): avc:  denied  { getattr } for  pid=938 comm="sendmail" path="/etc/mail" dev="sda1" ino=1177427 scontext=system_u:system_r:httpd_t:s0 tcontext=system_u:object_r:etc_mail_t:s0 tclass=dir


type=SYSCALL msg=audit(1376214118.953:640): arch=x86_64 syscall=lstat success=no exit=EACCES a0=7fff7c0e0610 a1=7fff7c0df580 a2=7fff7c0df580 a3=7fff7c0e061a items=0 ppid=794 pid=938 auid=4294967295 uid=990 gid=989 euid=990 suid=990 fsuid=990 egid=51 sgid=51 fsgid=51 ses=4294967295 tty=(none) comm=sendmail exe=/usr/sbin/sendmail.sendmail subj=system_u:system_r:httpd_t:s0 key=(null)

Hash: sendmail,httpd_t,etc_mail_t,dir,getattr

Additional info:
reporter:       libreport-2.1.6
hashmarkername: setroubleshoot
kernel:         3.10.5-201.fc19.x86_64
type:           libreport

Potential duplicate: bug 725899
Comment 1 Daniel Walsh 2013-08-14 08:27:11 EDT
The alert told you what to do.


*****  Plugin httpd_can_sendmail (91.4 confidence) suggests  *****************

If you want to allow httpd to send mail
Then you must setup SELinux to allow this
Do
setsebool -P httpd_can_sendmail=1
Comment 2 Daniel Walsh 2013-08-14 08:27:28 EDT
*** Bug 996824 has been marked as a duplicate of this bug. ***

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