diff --git a/README.md b/README.md index 18725f1f7..e39616a52 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ It's expected that the root hosted zone for the domain in question already exist 1. Install the letsencrypt-s3front plugin ``` - pip install letsencrypt-s3front + pip install letsencrypt-route53 ``` ### How to use it diff --git a/letsencrypt_route53/authenticator.py b/letsencrypt_route53/authenticator.py index 280a5bb55..95d24b0ab 100644 --- a/letsencrypt_route53/authenticator.py +++ b/letsencrypt_route53/authenticator.py @@ -36,7 +36,7 @@ class Authenticator(common.Plugin): def get_chall_pref(self, domain): # pylint: disable=missing-docstring,no-self-use,unused-argument - return [challenges.DNS] + return [challenges.DNS01] def perform(self, achalls): # pylint: disable=missing-docstring responses = [] @@ -48,8 +48,8 @@ class Authenticator(common.Plugin): # provision the TXT record, using the domain name given. Assumes the hosted zone exits, else fails the challenge response, validation = achall.response_and_validation() r53 = boto3.client('route53') - logger.info("Doing validation for " + achall) - listResponse = r53.list_hosted_zones_by_name(DNSName=achall.chall.path[1:]) + logger.info("Doing validation for " + response.domain) + listResponse = r53.list_hosted_zones_by_name(DNSName=response.domain) matches = listResponse.HostedZones; if matches.size != 0: logger.error("Route53 returned " + mathces.size + " matching hosted zones. Expected exactly one. Auth canceled.") @@ -62,7 +62,7 @@ class Authenticator(common.Plugin): { 'Action': 'UPSERT', 'ResourceRecordSet': { - 'Name': achall.chall.path[1:], + 'Name': achall.validation_domain_name(), 'Type': 'TXT', 'TTL': 300, 'ResourceRecords': [