workaround android bug with ssl certificates
This commit is contained in:
parent
87a8bfda47
commit
f858f69c56
|
@ -326,6 +326,8 @@ class Interface(threading.Thread):
|
||||||
dercert = s.getpeercert(True)
|
dercert = s.getpeercert(True)
|
||||||
s.close()
|
s.close()
|
||||||
cert = ssl.DER_cert_to_PEM_cert(dercert)
|
cert = ssl.DER_cert_to_PEM_cert(dercert)
|
||||||
|
# workaround android bug
|
||||||
|
cert = cert.replace("==-----END CERTIFICATE-----", "==\n-----END CERTIFICATE-----")
|
||||||
temporary_path = cert_path + '.temp'
|
temporary_path = cert_path + '.temp'
|
||||||
with open(temporary_path,"w") as f:
|
with open(temporary_path,"w") as f:
|
||||||
f.write(cert)
|
f.write(cert)
|
||||||
|
|
Loading…
Reference in New Issue