Skip to content

proxy: multiple credentials per user (aliases), streaming SigV4 re-signing - #290

Open
kwinston-dev wants to merge 4 commits into
clyso:mainfrom
kwinston-dev:proxy-alias-creds
Open

kwinston-dev wants to merge 4 commits into
clyso:mainfrom
kwinston-dev:proxy-alias-creds

Conversation

@kwinston-dev

Copy link
Copy Markdown

Finishes #237, closes #231. Proxy credentials are now user -> alias -> credential: any alias key authenticates as the user, so writes by other S3 users to a migrating bucket get replicated. The old flat format and dynamic creds without --alias still work (read as the alias named after the user).

Also fixes streaming SigV4 (aws-chunked) uploads through the proxy: chunk signatures are verified and re-signed for the storage.

Tests: MinIO e2e with a second user writing during migration, streaming PUT/UploadPart e2e, config and creds unit tests.

arttor and others added 4 commits November 12, 2026 16:14
Signed-off-by: Artem Torubarov <torubarov.a.a@gmail.com>
Signed-off-by: Artem Torubarov <torubarov.a.a@gmail.com>
- read pre-alias flat proxy credentials (user: {accessKeyID, secretAccessKey})
  as the alias named after the user, so existing proxy configs keep working
- proxy reads dynamic per-user S3 credentials (set without --alias) as the
  alias named after the user; explicit alias entries take precedence
- e2e test on MinIO: a second storage user with access to a migrating bucket
  writes through the proxy; its writes are captured as replication events
  during and after the initial migration

Signed-off-by: Ualikhan <yalikhan752@gmail.com>
Uploads signed with STREAMING-AWS4-HMAC-SHA256-PAYLOAD(-TRAILER) (minio-go
over plain http, some SDKs) were rejected by real backends: the proxy re-signs
the seed request with the storage credentials, but the per-chunk signatures in
the aws-chunked body were still chained from the client's seed signature and
secret.

The auth middleware now verifies every chunk (and signed trailer) signature
against the client key before releasing its data, and the forwarding client
replaces them with signatures chained from its own seed signature. Signatures
have a fixed length, so the framing and Content-Length are unchanged and signed
trailers (checksums) reach the storage.

Drops the test pinning the limitation and the DisableContentSha256
workarounds in test/minio.

Signed-off-by: Ualikhan <yalikhan752@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support multiple credentials in proxy config

2 participants