Commit 6b45d7ea authored by Julien Muchembled's avatar Julien Muchembled

Fix verification of expired certificates with recent OpenSSL

parent 44ec03af
......@@ -130,7 +130,10 @@ class Cert(object):
p = openssl('verify', '-CAfile', self.ca_path)
out, err = p.communicate(cert)
if p.returncode or strict:
for x in out.splitlines():
# BBB: With old versions of openssl, detailed
# error is printed to standard output.
for err in err, out:
for x in err.splitlines():
if x.startswith('error '):
x, msg = x.split(':', 1)
_, code, _, depth, _ = x.split(None, 4)
......
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