1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2024-12-22 07:17:05 +00:00

more for dnspython exception with IPv6 addresses

fixes #945, corrects prev commit (#947) in case of multiple AAAA records, adds changelog
This commit is contained in:
Joshua Tauberer 2016-09-23 07:37:17 -04:00
parent 163daea41c
commit c26bc841a2
2 changed files with 11 additions and 4 deletions

View File

@ -8,6 +8,10 @@ ownCloud:
* Updated to ownCloud to 8.2.7.
Control Panel:
* Fixed a crash that occurs when there are IPv6 DNS records due to a bug in dnspython 1.14.0.
v0.19b (August 20, 2016)
------------------------

View File

@ -245,12 +245,15 @@ def get_certificates_to_provision(env, show_extended_problems=True, force_domain
# https://github.com/rthalley/dnspython/issues/204
#
# BEGIN HOTFIX
if isinstance(response[0].to_text(), bytes):
response = [response[0].to_text().decode('utf-8')]
def rdata__str__(r):
s = r.to_text()
if isinstance(s, bytes):
s = s.decode('utf-8')
return s
# END HOTFIX
if len(response) != 1 or str(response[0]) != value:
problems[domain] = "Domain control validation cannot be performed for this domain because DNS points the domain to another machine (%s %s)." % (rtype, ", ".join(str(r) for r in response))
if len(response) != 1 or rdata__str__(response[0]) != value:
problems[domain] = "Domain control validation cannot be performed for this domain because DNS points the domain to another machine (%s %s)." % (rtype, ", ".join(rdata__str__(r) for r in response))
return False
return True