Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

User authentication #3

Closed
erwa opened this issue Nov 25, 2019 · 3 comments
Closed

User authentication #3

erwa opened this issue Nov 25, 2019 · 3 comments
Assignees

Comments

@erwa
Copy link
Contributor

erwa commented Nov 25, 2019

Currently, Small Board lets anyone create a user and password and see puzzles and submit answers. We should probably have users log in using Google Authentication and have a whitelist of users on Small Board to restrict who can see the puzzles and status.

@erwa erwa added the enhancement New feature or request label Nov 25, 2019
@erwa erwa removed the enhancement New feature or request label Nov 25, 2019
@asdfryan asdfryan added this to the Minimum Viable Product milestone Nov 25, 2019
@erwa
Copy link
Contributor Author

erwa commented Nov 25, 2019

We can use the list of users who have access to the hunt Google Drive to determine the list of valid users. File metadata has a "permissions" field that contains this info: http://googleapis.github.io/google-api-python-client/docs/dyn/drive_v3.files.html#get

@erwa erwa self-assigned this Nov 27, 2019
@erwa
Copy link
Contributor Author

erwa commented Nov 30, 2019

This is what the error message will look like if a user logs in but isn't in the email whitelist:

login-error

@erwa erwa closed this as completed in aa921d0 Nov 30, 2019
@erwa
Copy link
Contributor Author

erwa commented Nov 30, 2019

Added a GOOGLE_DRIVE_HUNT_FOLDER_ID environment variable, which should be set to the id of the base hunt Google Drive folder. The list of whitelisted emails (SOCIAL_AUTH_GOOGLE_OAUTH2_WHITELISTED_EMAILS) will be populated with the emails of the users who have access to the Google Drive folder.

If we add new users to the Google Drive folder, we'll need to restart Small Board for it to refresh the email whitelist.

npinsker added a commit that referenced this issue Jan 16, 2025
* just click on cells to edit them

* tweaks
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants