-
Notifications
You must be signed in to change notification settings - Fork 419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
X509Store.add_cert no longer raises an error on duplicate cert #787
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alex
reviewed
Aug 23, 2018
src/OpenSSL/crypto.py
Outdated
code = _lib.ERR_get_error() | ||
err_reason = _lib.ERR_GET_REASON(code) | ||
_openssl_assert( | ||
err_reason == _lib.X509_R_CERT_ALREADY_IN_HASH_TABLE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there any other errors that can happen?
alex
reviewed
Aug 23, 2018
CHANGELOG.rst
Outdated
@@ -23,7 +23,8 @@ Deprecations: | |||
Changes: | |||
^^^^^^^^ | |||
|
|||
*none* | |||
- ``X509Store.add_cert`` no longer raises an error if you add a duplicate cert. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be in the backwards incompat section
alex
approved these changes
Aug 23, 2018
peterbe
referenced
this pull request
in peterbe/django-peterbecom
Jan 22, 2019
This PR updates [pyOpenSSL](https://pypi.org/project/pyOpenSSL) from **18.0.0** to **19.0.0**. <details> <summary>Changelog</summary> ### 19.0.0 ``` ------------------- Backward-incompatible changes: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - ``X509Store.add_cert`` no longer raises an error if you add a duplicate cert. `787 <https://github.com/pyca/pyopenssl/pull/787>`_ Deprecations: ^^^^^^^^^^^^^ *none* Changes: ^^^^^^^^ - pyOpenSSL now works with OpenSSL 1.1.1. `805 <https://github.com/pyca/pyopenssl/pull/805>`_ - pyOpenSSL now handles NUL bytes in ``X509Name.get_components()`` `804 <https://github.com/pyca/pyopenssl/pull/804>`_ ---- ``` </details> <details> <summary>Links</summary> - PyPI: https://pypi.org/project/pyopenssl - Changelog: https://pyup.io/changelogs/pyopenssl/ - Homepage: https://pyopenssl.org/ - Docs: https://pythonhosted.org/pyOpenSSL/ </details>
peterbe
referenced
this pull request
in mozilla-services/tecken
Jan 22, 2019
This PR updates [pyOpenSSL](https://pypi.org/project/pyOpenSSL) from **18.0.0** to **19.0.0**. <details> <summary>Changelog</summary> ### 19.0.0 ``` ------------------- Backward-incompatible changes: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - ``X509Store.add_cert`` no longer raises an error if you add a duplicate cert. `787 <https://github.com/pyca/pyopenssl/pull/787>`_ Deprecations: ^^^^^^^^^^^^^ *none* Changes: ^^^^^^^^ - pyOpenSSL now works with OpenSSL 1.1.1. `805 <https://github.com/pyca/pyopenssl/pull/805>`_ - pyOpenSSL now handles NUL bytes in ``X509Name.get_components()`` `804 <https://github.com/pyca/pyopenssl/pull/804>`_ ---- ``` </details> <details> <summary>Links</summary> - PyPI: https://pypi.org/project/pyopenssl - Changelog: https://pyup.io/changelogs/pyopenssl/ - Homepage: https://pyopenssl.org/ - Docs: https://pythonhosted.org/pyOpenSSL/ </details>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
OpenSSL 1.1.0i changed X509_STORE_add_cert such that it no longer raises an error if a duplicate cert is added. This patch makes it so we behave consistently (and do not error) on all versions.