Skip to content

Commit

Permalink
Merge pull request #15 from gattjoe/1.8.1
Browse files Browse the repository at this point in the history
fixed some error handling
  • Loading branch information
ttyler01 authored Apr 20, 2021
2 parents 0693ad9 + 6179311 commit 9a98441
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions ocspchecker/ocspchecker.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,17 +117,17 @@ def get_certificate_chain(host: str, port: int) -> List[str]:
raise ValueError(f"{func_name}: {host} did not respond to the Client Hello.") from None

except WantReadError as err:
raise ValueError(f"{func_name}: err.strerror") from None
raise ValueError(f"{func_name}: {err.strerror}") from None

except WantX509LookupError as err:
raise ValueError(f"{func_name}: err.strerror") from None
raise ValueError(f"{func_name}: {err.strerror}") from None

except OpenSSLError as err:
if "1408F10B" in err.args[0]:
# https://github.com/openssl/openssl/issues/6805
raise ValueError(f"{func_name}: Remote host is not using SSL/TLS on port: {port}") from None

raise ValueError(f"{func_name}: err") from None
raise ValueError(f"{func_name}: {err}") from None

finally:
# shutdown() will also close the underlying socket
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

setup(
name="ocsp-checker",
version="1.8.0",
version="1.8.1",
description="Library used to check the OCSP revocation status for a x509 digital certificate.",
long_description=long_description,
long_description_content_type="text/markdown",
Expand Down

0 comments on commit 9a98441

Please sign in to comment.