-
Notifications
You must be signed in to change notification settings - Fork 27
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
Authorized Connection #12
Comments
The signaling server itself doesn't handle login/ passwords. This is a large task by itself and should be handled separately. Once a user has permission to access the server you could share an access token and check it in the request here: https://github.com/because-why-not/awrtc_signaling/blob/master/WebsocketNetworkServer.ts#L122 Do you have any specific systems / libraries in mind to handle the login? |
I want the signaling server access to be restricted to authorized users only. I'm creating something like a telephone service where one user can call another, but I want to limit the ability for others to connect using checks. That is, only users registered on my server can access the signaling server. Additionally, only two users (the one creating the room and the one for whom the room is created) can connect to the signaling server. I'm looking for ways to implement this task. So far, what I've come up with is using a special generation of room names, and having Nginx on the signaling server to receive data, process it, check availability, and if it's okay, then perform a redirect to the signaling server. However, this seems too complicated; it would be better if the signaling server itself could handle this. |
In most projects the signaling server is just a small puzzle piece in a larger project. I don't think it makes sense for it to decide how to manage users or how login works. These are decisions that will be different for every application. e.g. A more complex system might work like this:
Step 1-3 will be very different for each application e.g. one might be a 3D game that connects users when they are physically near each other and the next just connects all users using the same server or let the user decide each individual connection. What platforms and devices do you plan to target with your client side application? How do your users register and get authorised to access your server? What I could do is create a more advanced example in a separate repository that might give some starting point for this. |
Hello, I am currently using your Unity plugin for Android and iOS, with a main server running on Python, which uses a login and password to generate a token for interacting with the main server. As I understand, if your signaling server's server-side implementation is available, the Unity client version is closed for modification. I agree with and support your idea, but the question remains open—how to transmit the authorization token to the signaling server and how to conduct the verification. We could preliminarily agree on a method of encrypting the token to avoid setting up a direct link between the signaling and the main server, but the question of the token's acceptance and transmission by the signaling server remains unresolved. I would be grateful for a more detailed example, especially since I have not worked with Node.js before. Looking forward to your suggestions or guidelines on this matter. |
Ok I think I understand. With a python server it will be a bit more difficult. How about we do this with two tokens and a REST API call then: admin token: Allows access to a REST API to setup user tokens (for other servers) Usage might look like this:
Tokens are just strings for the signaling server so you can decide the details of them or reuse existing ones from python. Would that work for you? That seems like a useful addition to the server that is flexible enough for all use-cases. This change would also not require patching any of the other platforms. Just a server side is needed. |
look like awesome) |
I pushed a way to use tokens: https://github.com/because-why-not/awrtc_signaling/blob/master/README.md |
Thanks a lot! |
Hi guys, thanks for your job=)
However, how can I use login / password or better access_token for authentication on signal server?
The text was updated successfully, but these errors were encountered: