fix: allow sub-admin to modify password for other users (#11039)

fixes #11037
master
Harshavardhana 4 years ago committed by GitHub
parent 9c53cc1b83
commit 8d036ed6d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      cmd/admin-handlers-users.go

@ -387,9 +387,9 @@ func (a adminAPIHandlers) AddUser(w http.ResponseWriter, r *http.Request) {
implicitPerm := accessKey == cred.AccessKey
if !implicitPerm {
if !globalIAMSys.IsAllowed(iampolicy.Args{
AccountName: accessKey,
AccountName: cred.AccessKey,
Action: iampolicy.CreateUserAdminAction,
ConditionValues: getConditionValues(r, "", accessKey, claims),
ConditionValues: getConditionValues(r, "", cred.AccessKey, claims),
IsOwner: owner,
Claims: claims,
}) {

Loading…
Cancel
Save