Fix variable initialization so mailformed mails missing body From do not
cause a traceback (LP: #1844161)
This commit is contained in:
@@ -13,6 +13,8 @@
|
|||||||
as verifying works correctly
|
as verifying works correctly
|
||||||
- Add debug logging for content type to assist troubleshooting MIME
|
- Add debug logging for content type to assist troubleshooting MIME
|
||||||
conversion issues
|
conversion issues
|
||||||
|
- Fix variable initialization so mailformed mails missing body From do not
|
||||||
|
cause a traceback (LP: #1844161)
|
||||||
|
|
||||||
1.1.0 2019-04-12
|
1.1.0 2019-04-12
|
||||||
- Add SubDomains option to enable signing for sub-domains (LP: #1811535)
|
- Add SubDomains option to enable signing for sub-domains (LP: #1811535)
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ class dkimMilter(Milter.Base):
|
|||||||
self.privatersa = privateRSA
|
self.privatersa = privateRSA
|
||||||
self.privateed25519 = privateEd25519
|
self.privateed25519 = privateEd25519
|
||||||
self.fp = None
|
self.fp = None
|
||||||
|
self.fdomain = ''
|
||||||
|
|
||||||
@Milter.noreply
|
@Milter.noreply
|
||||||
def connect(self, hostname, unused, hostaddr):
|
def connect(self, hostname, unused, hostaddr):
|
||||||
@@ -141,7 +142,7 @@ class dkimMilter(Milter.Base):
|
|||||||
try:
|
try:
|
||||||
self.fdomain = self.author.split('@')[1].lower()
|
self.fdomain = self.author.split('@')[1].lower()
|
||||||
except IndexError as er:
|
except IndexError as er:
|
||||||
self.fdomain = '' # self.author was not a proper email address
|
pass # self.author was not a proper email address
|
||||||
if (milterconfig.get('Syslog') and
|
if (milterconfig.get('Syslog') and
|
||||||
milterconfig.get('debugLevel') >= 1):
|
milterconfig.get('debugLevel') >= 1):
|
||||||
syslog.syslog("{0}: {1}".format(name, val))
|
syslog.syslog("{0}: {1}".format(name, val))
|
||||||
|
|||||||
Reference in New Issue
Block a user