-
Notifications
You must be signed in to change notification settings - Fork 63
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
asks returns [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1051) #132
Comments
Traceback:
|
Looks like an anyio issue. Testing in browser, that url redirects you to the If you are not already logged in, you cannot access the domain you're aiming for. When requests and aiohttp return ok, they are not returning the actual accounts page, they are returning the subdomained login page here:
We can open an issue on anyio to see what we can do about not panicing on ssl stuff when we are 30x moved from one domain to a subdomain. |
Sure thing, I'll open up a issue when I find the time, thanks |
Continuing from the other side: this is an asks bug. The HTTP server returns a redirect in the form of |
As per anyio's creator: agronholm/anyio#67 asks calls Maybe this is related to my previous issue about asks mishandling redirections? #131 |
If I'm interpreting the RFC correctly, any missing components in the redirect URI (scheme, host, port) should be replaced with values from the current URI. As I understand, asks does not do this. |
@agronholm nice catch. Going to crack this open now. Time for a nice spring clean around redirects.
|
Hey @theelous3 did you manage to follow up with this? I'm getting the same issue when trying to request an IP from the port 80 that then redirects to HTTPs and has one of those mismatch certs. I use the ssl_context in all my sessions but on this case I think that the context is not passed on the redirect. |
Hey so I'm trying to send a GET request to spotify.com, and it constantly returns an SSL Error: wrong version number. It doesn't do this with requests or aiohttp, so I'm guessing asks is mishandling something
example code that triggers the error:
The text was updated successfully, but these errors were encountered: