-
Notifications
You must be signed in to change notification settings - Fork 146
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
Token Authorization #9
Comments
That's definitely something to look into. I will have to read up on the decisions from that Phoenix thread. Thanks for the suggestion! |
Hi @davidstump, Thank you for your positive reply. Thanks, |
This is pretty simple. Socket.connect needs to accept a dictionary and convert it to query string params to pass up with the websocket upgrade path. That's it! |
Just jotting down some notes here, regarding @chrismccord 's comments, and a brief discussion about it today. The deps/phoenix/web/static/js/phoenix.js comments mention the use of the params passed in the JS client, in this style: // let socket = new Socket("/ws", {params: {userToken: "123"}})
// socket.connect() Then it uses the |
Could you let me know if this got resolved with your PR? #17 |
@davidstump I think that PR is not enough. The params should be passed to server when the socket connection is built. |
Hi there,
Thank you for the awesome pod!
I'm building a chat app using this, but I want to check user authentication when socket joining.
It's related phoenixframework/phoenix#699 .
Do you have a plan to pass not only Phoenix.Message but something?
Best,
The text was updated successfully, but these errors were encountered: