-
Notifications
You must be signed in to change notification settings - Fork 312
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
Redirects to wss://...
don't work
#333
Comments
handle redirects that point to ws:// or wss:// details: coder/websocket#333
Hmm interesting. I'm not sure what browsers do here. Do they accept both on redirect? If so, we should too. I was under the impression they only used |
From the WebSocket spec1
Footnotes |
I don't see how that clarifies the issue at hand? It doesn't speak on whether the redirect URL should use |
Sorry I mean |
I'll make it work anyway. |
Done in dev but still needs a test. |
Done. |
If the server responds with
302 https://test.com/ws
the redirect works, but if the response is302 wss://test.com/ws
the redirect fails withfailed to WebSocket dial: failed to send handshake request: Get "wss://test.com/ws": unsupported protocol scheme "wss"
I was able to fix the issue by specifying a custom
http.Client
in theDialOptions
Do you think this should be included in the default client? I would be happy to open a PR with the functionality,
The text was updated successfully, but these errors were encountered: