Bug 614348 - SELinux is preventing /usr/libexec/dovecot/dovecot-lda "search" access on /var/log.
SELinux is preventing /usr/libexec/dovecot/dovecot-lda "search" access on /va...
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: selinux-policy (Show other bugs)
6.0
All Linux
medium Severity medium
: rc
: ---
Assigned To: Miroslav Grepl
Milos Malik
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-07-14 04:17 EDT by Jiri Kastner
Modified: 2012-09-21 08:41 EDT (History)
1 user (show)

See Also:
Fixed In Version: selinux-policy-3.7.19-32.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-11-10 16:35:18 EST
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 Jiri Kastner 2010-07-14 04:17:01 EDT
Summary:

SELinux is preventing /usr/libexec/dovecot/dovecot-lda "search" access on
/var/log.

Detailed Description:

[deliver has a permissive type (dovecot_deliver_t). This access was not denied.]

SELinux denied access requested by deliver. It is not expected that this access
is required by deliver 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://docs.fedoraproject.org/selinux-faq-fc5/#id2961385) Please file a bug
report.

Additional Information:

Source Context                system_u:system_r:dovecot_deliver_t:s0
Target Context                system_u:object_r:var_log_t:s0
Target Objects                /var/log [ dir ]
Source                        deliver
Source Path                   /usr/libexec/dovecot/dovecot-lda
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           dovecot-2.0-0.8.beta6.20100630.el6
Target RPM Packages           filesystem-2.4.30-2.1.el6
Policy RPM                    selinux-policy-3.7.19-31.el6
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux dhcp-25-175.brq.redhat.com
                              2.6.32-44.el6.x86_64 #1 SMP Wed Jul 7 15:47:50 EDT
                              2010 x86_64 x86_64
Alert Count                   327
First Seen                    Tue 13 Jul 2010 06:55:02 PM CEST
Last Seen                     Wed 14 Jul 2010 08:35:01 AM CEST
Local ID                      429348f1-145d-450b-886e-764d23b1e95f
Line Numbers                  

Raw Audit Messages            

node=localhost type=AVC msg=audit(1279089301.710:124): avc:  denied  { search } for  pid=12120 comm="deliver" name="log" dev=sda7 ino=3933736 scontext=system_u:system_r:dovecot_deliver_t:s0 tcontext=system_u:object_r:var_log_t:s0 tclass=dir

node=localhost type=SYSCALL msg=audit(1279089301.710:124): arch=c000003e syscall=2 success=yes exit=68719476864 a0=2295908 a1=441 a2=180 a3=10 items=0 ppid=12119 pid=12120 auid=4294967295 uid=500 gid=500 euid=500 suid=500 fsuid=500 egid=500 sgid=500 fsgid=500 tty=(none) ses=4294967295 comm="deliver" exe="/usr/libexec/dovecot/dovecot-lda" subj=system_u:system_r:dovecot_deliver_t:s0 key=(null)
Comment 1 Jiri Kastner 2010-07-14 04:20:14 EDT
i created var/log/dovecot-deliver.log and /var/log/dovecot-deliver-errors.log and because /usr/libexec/dovecot/deliver is executed under usual account using fetchmail, i assigned go+rw on those files, but selinux doesn't like that.
Comment 3 Daniel Walsh 2010-07-14 08:33:47 EDT
Does doevecot deliver need to write to these files?

Why didn't you create the log files in /var/log/dovecot which would label them correctly. Not that that would necessarily fix the issue.

Miroslav Rawhide has logging_search_logs(dovecot_auth_t) when it looks like it should be deliver_t.
Comment 4 Miroslav Grepl 2010-07-14 10:31:26 EDT
> Miroslav Rawhide has logging_search_logs(dovecot_auth_t) when it looks like it
> should be deliver_t.    

Fixed in selinux-policy-3.7.19-32.el6
Comment 7 releng-rhel@redhat.com 2010-11-10 16:35:18 EST
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

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