Bug 1031529 - dovecot-lda delivery cannot log, AVCs generated for each delivery attempt
dovecot-lda delivery cannot log, AVCs generated for each delivery attempt
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted (Show other bugs)
Unspecified Linux
unspecified Severity medium
: ---
: ---
Assigned To: Miroslav Grepl
Ben Levenson
Depends On:
  Show dependency treegraph
Reported: 2013-11-18 03:19 EST by Doug Maxey
Modified: 2015-02-17 14:17 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2015-02-17 14:17:11 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
dovecot-lda AVC (14.79 KB, text/plain)
2013-11-18 11:45 EST, Doug Maxey
no flags Details

  None (edit)
Description Doug Maxey 2013-11-18 03:19:42 EST
Description of problem:
Have been merrily running sendmail/dovecot on server that was f17.  Been a long time since I got that working.  It was even more fun this time :/

See the issues again where any delivery attempt made with dovecot-lda as the delivery agent fails because the /var/log/dovecot*.log files cannot be written

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. attempt to setup sendmail/dovecot combo

Actual results:
sendmail[9841]: rAI44Djm009073: to=me, delay=00:11:16, xdelay=00:00:00, mailer=local, pri=212311, dsn=4.0.0, stat=Deferred: local mailer (/usr/libexec/dovecot/dovecot-lda) exited with EX_TEMPFAIL

Matching with the above, as I worked my way though each recommended action:
setroubleshoot: SELinux is preventing /usr/libexec/dovecot/dovecot-lda from write access on the directory /var/log.
setroubleshoot: SELinux is preventing /usr/libexec/dovecot/dovecot-lda from add_name access on the directory dovecot-lda-errors.log.
setroubleshoot: SELinux is preventing /usr/libexec/dovecot/dovecot-lda from using the setgid capability.
setroubleshoot: SELinux is preventing /usr/libexec/dovecot/dovecot-lda from using the setuid capability.

Expected results:
mail is delivered.

Additional info:
This seems to have put a band-aid on it:

diff --git a/policy/dovecot-lda.te b/policy/dovecot-lda.te
new file mode 100644
index 0000000..92c6855
--- /dev/null
+++ b/policy/dovecot-lda.te
@@ -0,0 +1,14 @@
+module dovecot-lda 1.1;
+require {
+       type var_log_t;
+       type dovecot_deliver_t;
+       class capability setgid;
+       class capability setuid;
+       class dir { write add_name };
+#============= dovecot_deliver_t ==============
+allow dovecot_deliver_t self:capability { setgid setuid };
+allow dovecot_deliver_t var_log_t:dir { write add_name };
Comment 1 Daniel Walsh 2013-11-18 11:21:34 EST
Could you attach the actual AVC's for these denials.
Comment 2 Doug Maxey 2013-11-18 11:45:26 EST
Created attachment 825739 [details]
dovecot-lda AVC

grep dovecot-lda /var/log/audit/audit.log
Comment 3 Fedora End Of Life 2015-01-09 15:37:15 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

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.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 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, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

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.
Comment 4 Fedora End Of Life 2015-02-17 14:17:11 EST
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this

Thank you for reporting this bug and we are sorry it could not be fixed.

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