-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
ClientConnectorCertificateError / SSLCertVerificationError after update (regression) #9869
Comments
Please provide version numbers. Could maybe be related to the change to aiohappyeyeballs, but not too sure how. Otherwise, this typically indicates your certificates are not installed/accessible/up-to-date. You can use certifi (which requests uses by default) by following the docs: https://docs.aiohttp.org/en/stable/client_advanced.html#example-use-certifi |
Thanks a lot for your help! 😄 I got it working like this: async with aiohttp.ClientSession(
connector=aiohttp.TCPConnector(ssl=ssl.create_default_context(cafile=certifi.where())),
) as session:
... I am right now on Would love to see it working again by default without this additional "overhead". |
Without knowing the version, it's difficult to tell what might have changed. It could also be something else changed on your system that caused the system certificates to not be found. Or, maybe the site your connecting to has deployed a new certificate, with a CA that is not present in your system certificates. The aiohttp upgrade could just be a coincidence, so it'd need more testing to rule it out. |
I looked at the changes between 3.10 and 3.11 and didn't find anything related to SSL that would cause this. If I had to guess, I'd expect its due to a dependency change unless aiohttp was being upgraded from a very old version. |
Having similar problem after upgrading to Python 3.13: |
Thats likely due to the openssl version requiring the certificate to meet newest CAB forum requirements and comply with the RFC https://www.rfc-editor.org/rfc/rfc5280#section-4.2.1.9 |
Describe the bug
Great library which gave me nice performence improvements 😎
BUT unfortunately updating aiohttp dependency recently of a project causes ClientConnectorCertificateError / SSLCertVerificationError.
Using "requests" everything works as expected ✔️
Using "aiohttp" worked in the past (!) but raises now ❌
The only solution I found is
ssl=False
which is no option.Also "requests" uses ssl by default and there is no problem.
To Reproduce
see description.
Expected behavior
I expect this to work like it did before.
This is a breaking change (at least for me) so this was very unexpected and problematic.
Logs/tracebacks
Python Version
aiohttp Version
multidict Version
propcache Version
yarl Version
OS
Windows
Related component
Client
Additional context
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: