Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upPrevent client from including a request authorization header #38
Comments
This comment has been minimized.
This comment has been minimized.
What's the reasoning here? I guess I'm not sure what the relationship is meant to be between existing auth strategies on routes and the auth strategy used to authenticate the socket connection. |
This comment has been minimized.
This comment has been minimized.
The entire connection must have a single auth otherwise the security properties of this connection are undefined and fluid. |
This comment has been minimized.
This comment has been minimized.
Are credentials used to authenticate the socket connection also used with requests to routes over sockets? I mean, how would a route authentication strategies be applicable at all over sockets? This is very confusing to me. For example, I might have different bearer tokens for different routes based upon the auth strategies that are used for those routes. And if I can provide those tokens, then what's the problem? |
This comment has been minimized.
This comment has been minimized.
The WebSocket connection behaves like a single endpoint for authentication purposes. This is not a blank channel to send random HTTP requests over, each with their own headers. I have never seen a design where a single client uses multiple authentication credentials against one server. So if your requirements are to authenticate a single client using different credentials for different endpoints, this would not be the right solution for you. I am not going to allow changing authentication state once a channel is initialized. |
This comment has been minimized.
This comment has been minimized.
This makes more sense after seeing that the credentials/artifacts from the original websocket request are used when invoking routes to bypass any existing auth strategy. I didn't know that was happening, or that |
This comment has been minimized.
This comment has been minimized.
Happy to take a PR to make things clearer. The docs are not really for users at this point. They are mostly for me to keep track of everything I'm doing. At some point someone will need to write a proper guide for this module... It got big FAST. |
No description provided.