Repository navigation
fix(auth): disable password login and Fever when no password is set - #287
Merged
Merged
Conversation
In OIDC-only deployments (OIDC configured, FUSION_PASSWORD empty) the empty password was still hashed and accepted by POST /api/sessions, and the Fever API key was derived from it. Neither should exist without a configured password. - Treat a whitespace-only password as unset everywhere. - Without a password, skip hashing and do not register POST /api/sessions; GET/DELETE stay for OIDC sessions. - Fever: key from the password when set, unchanged in anonymous mode, empty (always auth:0) in OIDC-only mode, with a startup warning. - Add handler tests for OIDC-only, password and anonymous modes. Refs #276 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
nicnic-cc
added a commit
to nicnic-cc/refusion
that referenced
this pull request
Nov 23, 2026
- brings upstream's oidc-only auth fix (0x2E#287), which closes the same hole as our 652160e - keeps our passwordAuthDisabled guard and its test for now: dropping them deletes a committed test - docs/fever-api.md stays deleted, upstream's new lines went to .agents/notes/fever-api.md - go mod tidy raised x/tools and x/mod past upstream's pins because our deps are newer
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.
Summary
With OIDC configured and no password, the empty password was still treated as a credential. Auth methods now follow the configured credentials:
POST /api/sessionsmd5(user:password)auth:0md5(user:))Refs #276
Evidence
TestOIDCOnlyDisablesPasswordLoginAndFeveragainst the oldhandler.go: OIDC-only login returns 200 with a session cookie, and Fever returnsauth:1.After:
go test -count=1 ./...passes.FUSION_OIDC_ALLOWED_USER, and forged/replayed callbacks behave correctly. Password+OIDC and anonymous modes are unchanged.Merge Danger
Door: two-way
Blast Radius: auth
FUSION_PASSWORDset.FUSION_PASSWORDnow counts as unset. In anonymous mode the Fever key becomesmd5(user:).🤖 Generated with Claude Code