Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我们使用 Erlang/Cowboy 开发了一个基于 WebSockets 的简单聊天服务。现在,我们正在使用 localhost:8080 连接服务器。我想做用户身份验证,这将基于 URL 参数完成,它将返回用户 ID 或无连接。怎么做?
在 websocket 交换之前,您可以向您的应用程序请求一个令牌并将其与您的 websocket 客户端一起使用。