Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 08a13fea9e | |||
| 52c7ee02af | |||
| 791f8d80de | |||
| 7b37e2cb8d | |||
| 7be865d7d7 | |||
| e67a1b3745 | |||
| bf578e7b86 |
@@ -1,3 +1,9 @@
|
|||||||
|
1.2.2 2020-08-09
|
||||||
|
- Improve README.md formating for markdown display on pypi
|
||||||
|
- Improve documentation in dkimpy-milter.conf (5) and README.md for signing
|
||||||
|
for multiple domains (Thanks to Stefano Rivera)
|
||||||
|
- Minimal fix for dnspython 2.0.0 compatibility (still works with 1.16.0)
|
||||||
|
|
||||||
1.2.1 2020-01-04
|
1.2.1 2020-01-04
|
||||||
- Fix expand option not to fail if files are missing since socket activation
|
- Fix expand option not to fail if files are missing since socket activation
|
||||||
service files are not shipped in the sdist
|
service files are not shipped in the sdist
|
||||||
|
|||||||
@@ -52,6 +52,7 @@ The package includes a custom setup command called expand. It allows various
|
|||||||
file locations in init scripts, man pages, and config files to be over-ridden
|
file locations in init scripts, man pages, and config files to be over-ridden
|
||||||
at install time.
|
at install time.
|
||||||
|
|
||||||
|
|
||||||
expand: Expand @@ variables in input files, simlar to make macros.
|
expand: Expand @@ variables in input files, simlar to make macros.
|
||||||
user_options:
|
user_options:
|
||||||
--sysconfigdir=, e: Specify system configuration directory.
|
--sysconfigdir=, e: Specify system configuration directory.
|
||||||
@@ -135,9 +136,9 @@ for the above might look like this:
|
|||||||
comkey example.com:bar:/usr/local/etc/dkim/keys/excom
|
comkey example.com:bar:/usr/local/etc/dkim/keys/excom
|
||||||
netkey example.net:baz:/usr/local/etc/dkim/keys/exnet
|
netkey example.net:baz:/usr/local/etc/dkim/keys/exnet
|
||||||
|
|
||||||
If also signing with ed25519, specify a KeyTableEd25519 pointing to the keys
|
If also signing with ed25519, specify a KeyTableEd25519, with the same
|
||||||
needed for ed25519. Both KeyTable and KeyTableEd25519 are evaluated if there
|
names, pointing to the keys needed for ed25519. Both KeyTable and
|
||||||
is a SigningTable (see below).
|
KeyTableEd25519 are evaluated if there is a SigningTable (see below).
|
||||||
|
|
||||||
Per the documentation, multi-field data sets that are made of flat files have
|
Per the documentation, multi-field data sets that are made of flat files have
|
||||||
the fields separated by colons, but the key and value(s) are separated by
|
the fields separated by colons, but the key and value(s) are separated by
|
||||||
@@ -237,7 +238,7 @@ and deserve consideration.
|
|||||||
|
|
||||||
By default, sendmail quotes to address header fields when there are no
|
By default, sendmail quotes to address header fields when there are no
|
||||||
quotes and the display part of the address contains a period or an
|
quotes and the display part of the address contains a period or an
|
||||||
apostrophe. However, opendkim only sees the raw, unmodified form of
|
apostrophe. However, dkimpy-milter only sees the raw, unmodified form of
|
||||||
the header field, and so the content that gets verified and what gets
|
the header field, and so the content that gets verified and what gets
|
||||||
signed will not be the same, guaranteeing the attached signature is not
|
signed will not be the same, guaranteeing the attached signature is not
|
||||||
valid.
|
valid.
|
||||||
@@ -263,16 +264,16 @@ and deserve consideration.
|
|||||||
To: very long name <a@example.org>,
|
To: very long name <a@example.org>,
|
||||||
anotherloo...ong name b <b@example.org>
|
anotherloo...ong name b <b@example.org>
|
||||||
|
|
||||||
This rewrite is also done after opendkim has seen the message, meaning
|
This rewrite is also done after dkimpy-milter has seen the message,
|
||||||
the signature opendkim attaches to the message does not match the
|
meaning the signature dkimpy-milter attaches to the message does not match
|
||||||
content it signed. There is not a known configuration change to
|
the content it signed. There is not a known configuration change to
|
||||||
mitigate this mutation.
|
mitigate this mutation.
|
||||||
|
|
||||||
The only known mechanism for dealing with this is to have distinct
|
The only known mechanism for dealing with this is to have distinct
|
||||||
instances of opendkim do the verifying (inbound) and signing (outbound)
|
instances of dkimpy-milter do the verifying (inbound) and signing
|
||||||
so that the version that arrives at the signing instance is already
|
(outbound) so that the version that arrives at the signing instance is
|
||||||
in the rewritten form, guaranteeing the input and output are the same
|
already in the rewritten form, guaranteeing the input and output are the
|
||||||
and thus the signature matches the payload.
|
same and thus the signature matches the payload.
|
||||||
|
|
||||||
### POSTFIX
|
### POSTFIX
|
||||||
|
|
||||||
|
|||||||
@@ -363,8 +363,12 @@ class dkimMilter(Milter.Base):
|
|||||||
try:
|
try:
|
||||||
dnsoverride = self.conf.get('DNSOverride')
|
dnsoverride = self.conf.get('DNSOverride')
|
||||||
if isinstance(dnsoverride, str):
|
if isinstance(dnsoverride, str):
|
||||||
|
timeout = 5
|
||||||
|
domain = self.fdomain
|
||||||
|
def dnsfunc(domain, timeout=timeout, dnsoverride=dnsoverride):
|
||||||
|
return dnsoverride
|
||||||
syslog.syslog("DNSOverride: {0}".format(dnsoverride))
|
syslog.syslog("DNSOverride: {0}".format(dnsoverride))
|
||||||
res = d.verify(idx=y, dnsfunc=lambda _x: dnsoverride)
|
res = d.verify(idx=y, dnsfunc=dnsfunc)
|
||||||
else:
|
else:
|
||||||
res = d.verify(idx=y)
|
res = d.verify(idx=y)
|
||||||
algo = codecs.decode(d.signature_fields.get(b'a'), 'ascii')
|
algo = codecs.decode(d.signature_fields.get(b'a'), 'ascii')
|
||||||
|
|||||||
@@ -127,7 +127,7 @@ def DNSLookup_dnspython(name,qtype,tcpfallback=True,timeout=5):
|
|||||||
elif qtype == 'PTR':
|
elif qtype == 'PTR':
|
||||||
retVal.append(((name, qtype), rdata.target.to_text(True)))
|
retVal.append(((name, qtype), rdata.target.to_text(True)))
|
||||||
elif qtype == 'TXT' or qtype == 'SPF':
|
elif qtype == 'TXT' or qtype == 'SPF':
|
||||||
retVal.append(((name, qtype), rdata.strings))
|
retVal.append(((name, qtype), list(rdata.strings)))
|
||||||
except dns.resolver.NoAnswer:
|
except dns.resolver.NoAnswer:
|
||||||
pass
|
pass
|
||||||
except dns.resolver.NXDOMAIN:
|
except dns.resolver.NXDOMAIN:
|
||||||
|
|||||||
@@ -428,7 +428,7 @@ of this field.
|
|||||||
.TP
|
.TP
|
||||||
.I SigningTable (dataset)
|
.I SigningTable (dataset)
|
||||||
|
|
||||||
Defines a table used to select one or more signing identities to apply to a message based on the address found in the From: header field. Keys in this table vary depending on the type of table used; values in this data set should include one field that contains a name found in the KeyTable (see above) that identifies which key should be used in generating the signature, and an optional second field naming the signer of the message that will be included in the "i=" tag in the generated signature. Note that the "i=" value will not be included in the signature if it conflicts with the signing domain (the "d=" value).
|
Defines a table used to select a signing identity to apply to a message based on the address found in the From: header field. Keys in this table vary depending on the type of table used; values in this data set should include one field that contains a name found in the KeyTable (see above) that identifies which key should be used in generating the signature, and an optional second field naming the signer of the message that will be included in the "i=" tag in the generated signature. Note that the "i=" value will not be included in the signature if it conflicts with the signing domain (the "d=" value).
|
||||||
|
|
||||||
If the first field contains only a "%" character, it will be replaced by the domain found in the From: header field. Similarly, within the optional second field, any "%" character will be replaced by the domain found in the From: header field.
|
If the first field contains only a "%" character, it will be replaced by the domain found in the From: header field. Similarly, within the optional second field, any "%" character will be replaced by the domain found in the From: header field.
|
||||||
|
|
||||||
|
|||||||
@@ -89,7 +89,7 @@ except ImportError: # If PyDNS is not installed, prefer dnspython
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name='dkimpy-milter',
|
name='dkimpy-milter',
|
||||||
version='1.2.1',
|
version='1.2.2',
|
||||||
author='Scott Kitterman',
|
author='Scott Kitterman',
|
||||||
author_email='scott@kitterman.com',
|
author_email='scott@kitterman.com',
|
||||||
url='https://launchpad.net/dkimpy-milter',
|
url='https://launchpad.net/dkimpy-milter',
|
||||||
|
|||||||
Reference in New Issue
Block a user