Skip to content
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

cryptography 37.0.0 Not Compatible with pyOpenSSL #7126

Closed
ulriksenstian opened this issue Apr 27, 2022 · 7 comments
Closed

cryptography 37.0.0 Not Compatible with pyOpenSSL #7126

ulriksenstian opened this issue Apr 27, 2022 · 7 comments

Comments

@ulriksenstian
Copy link

Receiving the following error when importing pyOpenSSL:
AttributeError: module 'lib' has no attribute 'X509_V_FLAG_CB_ISSUER_CHECK'.

Downgrading to 36.0.2 solved this issue.

@ulriksenstian
Copy link
Author

pyOpenSSL 22.0.0

@alex
Copy link
Member

alex commented Apr 27, 2022

X509_V_FLAG_CB_ISSUER_CHECK does not exist in pyOpenSSL 22.0.0, you are using an older version of pyOpenSSL with a brand new cryptography.

See also pyca/pyopenssl#1114

@ulriksenstian
Copy link
Author

Our pip install in Databricks didn't actually install correctly. It is working now with PyOpenSSL==22.0.0

@reywood
Copy link

reywood commented Apr 27, 2022

@alex Just a question. Is there a reason a new revision of pyOpenSSL 19 isn't released to pin the cryptography dependency to < 37?

@alex
Copy link
Member

alex commented Apr 27, 2022

Several reasons:

  1. In general we don't go back and issue point point releases on several year old versions of pyOpenSSL (maybe we should, but that's never been practice thus far)
  2. Users who are precisely pinned to ==some release won't benefit from that in anyways, it only helps people who have version range pins. We have no idea of the relative frequency of one pinning strategy vs. another.
  3. A much better fix is if pip would let us express "not compatible with" in cryptography's setup.cfg, then we could get folks useful error messages.

@reywood
Copy link

reywood commented Apr 27, 2022

Cool. Thanks for the insight.

@reaperhulk
Copy link
Member

For this specific instance (where we removed bindings that we only stopped using in pyOpenSSL 22.0.0, released in late January) we've chosen to temporarily revert that change and restore the bindings in 37.0.1. However, we'll remove them again in a future release so the best advice remains to always upgrade pyOpenSSL if you upgrade cryptography.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

4 participants