-
Notifications
You must be signed in to change notification settings - Fork 715
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(server): Lobby server improvements (#532)
* fix(server): Assign seat credentials when a player joins a room Addresses potential for leaking credentials identified in #429. Credentials for each seat are now set when a player joins a room and then deleted when the player leaves. * feat(server): Allow customised `generateCredentials` lobby config Setting a `generateCredentials` method in the lobbyConfig customises the credentials stored in gameMetadata and returned to players when the join a room. `generateCredentials` is called with Koa’s `ctx` object to allow credentials to depend on request content/headers, and can be asynchronous to permit calling third-party services. * feat(master): Allow asynchronous authentication checks * feat(server): Use options object to configure socket.io server transport * feat(server): Allow master’s auth option to be set via SocketIO * feat(server): Add `authenticateCredentials` option to server * refactor(server): Move `generateCredentials` option to Server factory * docs(api): Document custom authentication approaches * docs(api): Remove “custom” from Server API docs Co-authored-by: Nicolo John Davis <nicolodavis@gmail.com>
- Loading branch information
1 parent
b3e0bdc
commit 4d33faa
Showing
8 changed files
with
143 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters