Skip to content

Commit

Permalink
ZCS-16295: fixed change password
Browse files Browse the repository at this point in the history
  • Loading branch information
k-kato authored and dasiyogesh committed Jan 27, 2025
1 parent 3d845a4 commit c3f5779
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,10 @@ public Element handle(Element request, Map<String, Object> context) throws Servi
throw ServiceException.PERM_DENIED("cannot access account");
}

acct = AuthProvider.validateAuthToken(prov, at, false, usage);
Account authTokenAcct = AuthProvider.validateAuthToken(prov, at, false, usage);
if (!AuthToken.isAnyAdmin(at)) {
acct = authTokenAcct;
}
if (acct == null) {
throw AuthFailedServiceException.AUTH_FAILED(name, namePassedIn, "account not found");
}
Expand Down

0 comments on commit c3f5779

Please sign in to comment.