Add support for storing DKIM failed mails in a specified DiagnosticDirectory

This commit is contained in:
Scott Kitterman
2019-12-24 14:43:14 -05:00
parent db268764f5
commit 042005b38d
5 changed files with 14 additions and 7 deletions
+2
View File
@@ -8,6 +8,8 @@
- Install openrc init file for Gentoo and other openrc users
- Add support for passing PID file name on command line to make it easier to
keep system init and daemon configuration in sync
- Add support for storing DKIM failed mails in a specified
DiagnosticDirectory
- Fix startup logging so it provides information at a useful time
- Fix verify processing so missing (optional) i= tag doesn't cause the milter
to fail (LP: #1842250)
+1 -1
View File
@@ -56,7 +56,7 @@ KeytableEd25519 implemented verified
MinimumKeyBits implemented verified
SignHeaders implemented verified by inspection
SigningTable implemented verified
TemporaryDirectory
TemporaryDirectory implemented verified by inspection
Planned dataset type support (if needed):
mdb:
+1
View File
@@ -413,6 +413,7 @@ class dkimMilter(Milter.Base):
self.dkim_domain = d.domain.lower()
else:
if self.conf.get('DiagnosticDirectory'):
tempfile.tempdir = self.conf.get('DiagnosticDirectory')
fd, fname = tempfile.mkstemp(".dkim")
with os.fdopen(fd, "w+b") as fp:
fp.write(txt)
+5 -3
View File
@@ -211,9 +211,11 @@ header and the second to the body.
.TP
.I DiagnosticDirectory (string)
Directory into which to write diagnostic reports when message verification
fails. If not set (the default), these files are not generated. [Unlike
OpenDKIM, this applies to all messages, not just on messages bearing a "z=" tag
because dkimpy does not yet support "z=".]
fails. If not set (the default), these files are not generated. The
directory must exist, dkimpy-milter will not create it and an error will be
raised if it does not. [Unlike OpenDKIM, this applies to all messages, not
just on messages bearing a "z=" tag because dkimpy does not yet support
"z=" processing.]
.TP
.I Domain (dataset)
+5 -3
View File
@@ -211,9 +211,11 @@ header and the second to the body.
.TP
.I DiagnosticDirectory (string)
Directory into which to write diagnostic reports when message verification
fails. If not set (the default), these files are not generated. [Unlike
OpenDKIM, this applies to all messages, not just on messages bearing a "z=" tag
because dkimpy does not yet support "z=".]
fails. If not set (the default), these files are not generated. The
directory must exist, dkimpy-milter will not create it and an error will be
raised if it does not. [Unlike OpenDKIM, this applies to all messages, not
just on messages bearing a "z=" tag because dkimpy does not yet support
"z=" processing.]
.TP
.I Domain (dataset)