mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-22 02:17:26 +00:00
whats_next: when there are multiple responses like for NS records sort the responses so we can compare to a fixed order
This commit is contained in:
parent
f299825a95
commit
919a5a8f0b
@ -248,8 +248,9 @@ def query_dns(qname, rtype, nxdomain='[Not Set]'):
|
|||||||
|
|
||||||
# There may be multiple answers; concatenate the response. Remove trailing
|
# There may be multiple answers; concatenate the response. Remove trailing
|
||||||
# periods from responses since that's how qnames are encoded in DNS but is
|
# periods from responses since that's how qnames are encoded in DNS but is
|
||||||
# confusing for us.
|
# confusing for us. The order of the answers doesn't matter, so sort so we
|
||||||
return "; ".join(str(r).rstrip('.') for r in response)
|
# can compare to a well known order.
|
||||||
|
return "; ".join(sorted(str(r).rstrip('.') for r in response))
|
||||||
|
|
||||||
def check_ssl_cert(domain, env):
|
def check_ssl_cert(domain, env):
|
||||||
# Check that SSL certificate is signed.
|
# Check that SSL certificate is signed.
|
||||||
|
Loading…
Reference in New Issue
Block a user