1
0
mirror of https://github.com/github/octodns.git synced 2024-05-11 05:55:00 +00:00

Fix trailing semicolon in dkim for ovh provider

Pulling dns records from ovh to a yaml file puts a semicolon at the end.
Pushing from yaml to ovh will fail the "dkim-compliant" verification if
there is an empty field (and there is one in case of a trailing
semicolon). With the current logic, pulling dkim record created with ovh
then pushing it back will NOT work.

This small patch ignores all empty fields in a dkim records during dkim
validation.
This commit is contained in:
Charles Durieux
2020-01-08 17:45:02 +01:00
parent 84b7cd88bc
commit e22a7d2738

View File

@@ -323,7 +323,7 @@ class OvhProvider(BaseProvider):
'n': lambda _: True,
'g': lambda _: True}
splitted = value.split('\\;')
splitted = list(filter(None, value.split('\\;')))
found_key = False
for splitted_value in splitted:
sub_split = [x.strip() for x in splitted_value.split("=", 1)]