Commit c322bb6f authored by Stephane Bortzmeyer's avatar Stephane Bortzmeyer
Browse files

Debug code forgotten

parent 0bce0cf5
......@@ -102,7 +102,6 @@ def get_certificate_san(x509cert):
# Try one possible name. Names must be already canonicalized.
def match_hostname(hostname, possibleMatch):
print("Testing %s against %s" % (hostname, possibleMatch))
if possibleMatch.startswith("*."): # Wildcard
base = possibleMatch[1:] # Skip the star
# RFC 6125 says that we MAY accept left-most labels with
......@@ -145,7 +144,6 @@ def validate_hostname(hostname, cert):
base_i = netaddr.IPAddress(base)
except netaddr.core.AddrFormatError:
continue # Ignore broken IP addresses in certificates. Are we too liberal?
print("Testing %s against %s" % (hostname, base))
if host_i == base_i:
return True
else:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment