Repository navigation
fix(auth): keep users with a filter out of setup - #5617
Merged
Merged
Conversation
Setup applies to the whole instance but only checked roles. An empty roles key means all, so a user confined by a filter passed as if they were an admin. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Claude finished @amir20's task in 48s —— View job 0 findings. Nothing to fix. What I readI read the whole diff: Why it's correct
Not run
|
Contributor
|
Try this PR without waiting for a release: Also on |
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.
Setup applies to the whole instance, but the check only looked at roles. An empty
roles:meansall, so a user with a filter passed it too. Now a filter rules you out, same aspruneHost.Users with a filter and every role lose setup after this. Unfiltered users and no-login installs don't change.
Also adds the roles vs filters rule to
CLAUDE.md, and a line about it to the auth docs in all locales.Tests
TestSetup_FilteredUserCannotWriteandTest_setupCanWrite_EveryLoginProviderfail on main (200/201/202/204 on every setup write, expected 403) and pass here.TestSetup_UnfilteredUserStillWritespasses. Forward proxy goes through the real router, simple and oidc call the check directly, and no-login is covered by the existing setup tests.🤖 Generated with Claude Code