mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-11-13 15:29:12 +01:00
s3api: take a session's aws:userid from its signed parent user
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
e456d891a4
commit
a0d69a7ede
1 file changed
+5
@@ -539,6 +539,11 @@ func (iam *IdentityAccessManagement) validateSTSSessionToken(r *http.Request, se
|
||||
} else {
|
||||
delete(claims, "aws:username")
|
||||
}
|
||||
if sessionInfo.ParentUser != "" {
|
||||
claims["aws:userid"] = sessionInfo.ParentUser
|
||||
} else {
|
||||
delete(claims, "aws:userid")
|
||||
}
|
||||
|
||||
// Key the principal on the OIDC subject so a session resolves to the same
|
||||
// identity on the SigV4 and JWT paths (see s3_iam_middleware.go); fall back to
|
||||
|
||||
Reference in new issue
Block a user