Bug 1031529 - dovecot-lda delivery cannot log, AVCs generated for each delivery attempt
Summary: dovecot-lda delivery cannot log, AVCs generated for each delivery attempt
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted
Version: 19
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Ben Levenson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-11-18 08:19 UTC by Doug Maxey
Modified: 2015-02-17 19:17 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2015-02-17 19:17:11 UTC
Type: Bug
Embargoed:


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

Description Doug Maxey 2013-11-18 08:19:42 UTC
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):
dovecot-2.2.7-2.fc19.x86_64
sendmail-8.14.7-1.fc19.x86_64
selinux-policy-targeted-3.12.1-74.11.fc19.noarch


How reproducible:
100%

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

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 16:21:34 UTC
Could you attach the actual AVC's for these denials.

Comment 2 Doug Maxey 2013-11-18 16:45:26 UTC
Created attachment 825739 [details]
dovecot-lda AVC

grep dovecot-lda /var/log/audit/audit.log

Comment 3 Fedora End Of Life 2015-01-09 20:37:15 UTC
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 19:17:11 UTC
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
bug.

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.