From f15db8f93229aa2323e03f75938969e0243b62bf Mon Sep 17 00:00:00 2001 From: Brian Cunnie Date: Sun, 4 Mar 2018 12:11:36 -0800 Subject: [PATCH] Root A and AAAA records return properly for mixed-case queries When queried with a mixed-case domain, e.g. "SsLiP.Io", the A and AAAA records are properly returned. Previously they weren't. This is a problem when Let's Encrypt queries with a mixed-case domain, which it does for reasons which are not clear: fixes: ``` Failed authorization procedure. sslip.io (http-01): urn:acme:error:unknownHost :: The server could not resolve a domain name :: No valid IP addresses found for sslip.io ``` --- conf/sslip.io+nono.io.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/conf/sslip.io+nono.io.yml b/conf/sslip.io+nono.io.yml index cce0895..42cf5b7 100644 --- a/conf/sslip.io+nono.io.yml +++ b/conf/sslip.io+nono.io.yml @@ -234,7 +234,8 @@ pdns_pipe: | answer_mx_query fi if qtype_is "A"; then - if [ $QNAME == $XIP_DOMAIN ]; then + LC_QNAME=$(echo $QNAME | tr 'A-Z' 'a-z') + if [ $LC_QNAME == $XIP_DOMAIN ]; then answer_root_a_query else if subdomain_is_dashed_ip; then @@ -246,7 +247,8 @@ pdns_pipe: | fi if qtype_is "AAAA"; then - if [ $QNAME == $XIP_DOMAIN ]; then + LC_QNAME=$(echo $QNAME | tr 'A-Z' 'a-z') + if [ $LC_QNAME == $XIP_DOMAIN ]; then answer_root_aaaa_query else if subdomain_is_dashed_ipv6; then