Added iam import tests for openid (#20432)

Tests if imported service accounts have 
required access to buckets and objects.

Signed-off-by: Shubhendu Ram Tripathi <shubhendu@minio.io>

Co-authored-by: Harshavardhana <harsha@minio.io>
This commit is contained in:
Shubhendu
2024-09-17 22:15:46 +05:30
committed by GitHub
parent 3c82cf9327
commit 5bd27346ac
9 changed files with 165 additions and 50 deletions

View File

@@ -245,6 +245,22 @@ func NewMapClaims() *MapClaims {
return &MapClaims{MapClaims: jwtgo.MapClaims{}}
}
// Set Adds new arbitrary claim keys and values.
func (c *MapClaims) Set(key string, val interface{}) {
if c == nil {
return
}
c.MapClaims[key] = val
}
// Delete deletes a key named key.
func (c *MapClaims) Delete(key string) {
if c == nil {
return
}
delete(c.MapClaims, key)
}
// Lookup returns the value and if the key is found.
func (c *MapClaims) Lookup(key string) (value string, ok bool) {
if c == nil {