Introduces a very simple authentication system that in summary: Generates a unique token for the player when they join the table. Then the client stores that token in the browsers localStorage. Then when sending requests to the server relative to this table, it will pull the token and add it to the Authorization Header. And all player related endpoints besides /join will confirm that the token matches the player that is being requested on.
Linked Issue
resolves #215
Types of changes
[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
Merge Checklist
[x] My code follows the code style of this project.
[x] All new and existing tests passed.
[x] Any dependent changes have been merged in downstream modules.
[x] I have provided inline technical documentation (tsdocs) where necessary.
[ ] My change requires a change to the root documentation.
Proposed Changes
Introduces a very simple authentication system that in summary: Generates a unique
token
for the player when they join the table. Then the client stores that token in the browserslocalStorage
. Then when sending requests to the server relative to this table, it will pull thetoken
and add it to theAuthorization
Header. And all player related endpoints besides/join
will confirm that thetoken
matches the player that is being requested on.Linked Issue
resolves #215
Types of changes
Merge Checklist
Deployment Notes