[WIP] Prototype of a username/password authentication system#285
Draft
plotfi wants to merge 1 commit into
Draft
Conversation
Adds require_auth and require_admin_auth config flags. When require_auth is enabled, only registered users can connect and must provide a password. Admins identified by SSH key hash bypass auth unless require_admin_auth is also set. Passwords are bcrypt-hashed and stored in user-auth.json. Prefs are keyed by authenticated username rather than IP-based ID. Sensitive commands (adduser, removeuser, passwd) are intercepted before room broadcast to prevent password leakage.
Contributor
|
Devzat already has an allowlist which enables similar functionality to this but using ssh keys. Adding password auth would be a major change to how Devzat works. It also honestly doesn't make any sense to have password auth and passkey auth and setting the server to public (to enable connecting w/o passkey on :443) is the opposite of your intentions. I would always suggest opening an issue with your idea before spending tokens to see if (AI Generation) of the Idea is even appreciated. |
Author
|
@PPTide Does the allowlist get hot-reloaded or does it require a restart? Also, does it prevent new users from signing on or does it merely reserve usernames? Sorry to bother if this all should be more obvious. |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Full disclosure, I prototyped this using Claude. But I still think its straight forward enough to look at as inspiration for a username/password login system.