fix(policy)!: separate password self service and update upstream SDK - #6
Merged
Conversation
Adapt minio/pkg minio#262 and minio#233: use ChangeMyPassword for self service, require explicit CreateUser grants, and add consolereadonly. Preserve legacy-policy parsing and cover explicit deny combinations. Pin minio-go to upstream 78bfa91607c2 and record the upstream review. Signed-off-by: Feng Ruohang <rh@vonng.com>
This was referenced Sep 10, 2026
Signed-off-by: Feng Ruohang <rh@vonng.com>
Vonng
marked this pull request as ready for review
September 10, 2026 09:17
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.
Self-service password changes currently share the reported
admin:CreateUsercapability with privileged user administration. Adapt minio/pkg minio#262 soadmin:ChangeMyPasswordis implicit unless denied, while CreateUser requires an explicit grant. Remove the built-in readonly CreateUser deny and adopt minio#233's consolereadonly policy with the same split.Pin minio-go to upstream
78bfa91607c2and record the upstream review inUPSTREAM.md. SDK #2301 is included; #2274 remains open upstream and is deferred. Existing SILO policy correctness fixes and the Go 1.26 floor are retained.Breaking authorization compatibility: the Go signatures are retained, but
Policy.IsAllowedActionsreturns different capabilities. With the matching Server, a saved CreateUser deny no longer locks the caller's password, and a ChangeMyPassword deny now locks it. To preserve the old combined restriction, deny both actions in the same statement before upgrading. The new built-inreadonlyalso stops overriding a separate CreateUser grant; saved overrides retain their existing denies. Policies are not rewritten automatically. This permission-design change is independent of updating the SDK and must be disclosed as breaking in the release that includes it.This must ship with Server #175, Console #51 and mcli #41. See the migration guide for the before/after matrix, saved read-only policies, mixed-version rollout and rollback. An old Server cannot enforce a password-only deny for this endpoint. No release tag is created here.
Validation:
make test(lint and all package tests with race detection)GOWORK=off GOTOOLCHAIN=go1.26.0 go test ./...go test -short -race ./...at the pinned upstream versiongit diff --checkpasses, with no runtime or dependency changesNo authorization hot-path algorithm changes are introduced.
IsAllowedActionsretains its existing iteration structure.