mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-10-19 05:58:34 +02:00
Bugfix: DKIM checks fail
The DKIM key is base64 encoded, meaning it can end with "=" signs
Split on "=" and check if you have 2 'parts' (key and value) will fail in these cases.
By using split("=",1) we make sure we only slit on the first occurence of the "=" sign
This commit is contained in:
@@ -200,7 +200,7 @@ def check_dkim_syntax(record):
|
||||
key = None
|
||||
for tag in record.split(";")[1:]:
|
||||
tag = tag.strip(" ")
|
||||
parts = tag.split("=")
|
||||
parts = tag.split("=",1)
|
||||
if len(parts) != 2:
|
||||
raise DNSSyntaxError(_("Invalid tag {}").format(tag))
|
||||
name = parts[0].strip(" ")
|
||||
|
||||
Reference in New Issue
Block a user