diff --git a/CHANGELOG.md b/CHANGELOG.md index e4602f9..36bf368 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## v0.0.? - 2024-??-?? - + +* Fix CAA rdata parsing to allow values with tags + ## v0.0.7 - 2024-04-11 - Helps if you use the actual Session token ### Important diff --git a/octodns_route53/provider.py b/octodns_route53/provider.py index ee50e86..959aa3a 100644 --- a/octodns_route53/provider.py +++ b/octodns_route53/provider.py @@ -913,7 +913,7 @@ def _data_for_geo(self, rrset): def _data_for_CAA(self, rrset): values = [] for rr in rrset['ResourceRecords']: - flags, tag, value = rr['Value'].split() + flags, tag, value = rr['Value'].split(' ', 2) values.append({'flags': flags, 'tag': tag, 'value': value[1:-1]}) return { 'type': rrset['Type'], diff --git a/tests/test_octodns_provider_route53.py b/tests/test_octodns_provider_route53.py index d73e620..fb31396 100644 --- a/tests/test_octodns_provider_route53.py +++ b/tests/test_octodns_provider_route53.py @@ -401,7 +401,11 @@ class TestRoute53Provider(TestCase): { 'ttl': 69, 'type': 'CAA', - 'value': {'flags': 0, 'tag': 'issue', 'value': 'ca.unit.tests'}, + 'value': { + 'flags': 0, + 'tag': 'issue', + 'value': 'ca.unit.tests; cansignhttpexchanges=yes', + }, }, ), ( @@ -1125,7 +1129,11 @@ def test_populate(self): { 'Name': 'unit.tests.', 'Type': 'CAA', - 'ResourceRecords': [{'Value': '0 issue "ca.unit.tests"'}], + 'ResourceRecords': [ + { + 'Value': '0 issue "ca.unit.tests; cansignhttpexchanges=yes"' + } + ], 'TTL': 69, }, {