mirror of
https://github.com/minio/minio.git
synced 2025-11-08 21:24:55 -05:00
support 'ldap:user' variable replacement properly (#10391)
also update `ldap.go` examples with latest minio-go changes Fixes #10367
This commit is contained in:
@@ -151,9 +151,10 @@ func getConditionValues(r *http.Request, lc string, username string, claims map[
|
||||
if ok {
|
||||
// Special case for AD/LDAP STS users
|
||||
if k == ldapUser {
|
||||
args[ldapUserPolicyVariable] = []string{vStr}
|
||||
args["user"] = []string{vStr}
|
||||
} else {
|
||||
args[k] = []string{vStr}
|
||||
}
|
||||
args[k] = []string{vStr}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -61,8 +61,7 @@ const (
|
||||
parentClaim = "parent"
|
||||
|
||||
// LDAP claim keys
|
||||
ldapUser = "ldapUser"
|
||||
ldapUserPolicyVariable = "ldap:user"
|
||||
ldapUser = "ldapUser"
|
||||
)
|
||||
|
||||
// stsAPIHandlers implements and provides http handlers for AWS STS API.
|
||||
|
||||
Reference in New Issue
Block a user