You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: server/src/main/java/com/cloud/user/AccountManagerImpl.java
+8Lines changed: 8 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1510,6 +1510,8 @@ public UserAccount updateUser(UpdateUserCmd updateUserCmd) {
1510
1510
* <ul>
1511
1511
* <li> If 'password' is blank, we throw an {@link InvalidParameterValueException};
1512
1512
* <li> If 'current password' is not provided and user is not an Admin, we throw an {@link InvalidParameterValueException};
1513
+
* <li> If the user whose password is being changed has a source equal to {@link User.Source#SAML2}, {@link User.Source#SAML2DISABLED} or {@link User.Source#LDAP},
1514
+
* we throw an {@link InvalidParameterValueException};
1513
1515
* <li> If a normal user is calling this method, we use {@link #validateCurrentPassword(UserVO, String)} to check if the provided old password matches the database one;
1514
1516
* </ul>
1515
1517
*
@@ -1524,6 +1526,12 @@ public void validateUserPasswordAndUpdateIfNeeded(String newPassword, UserVO use
1524
1526
thrownewInvalidParameterValueException("Password cannot be empty or blank.");
s_logger.warn(String.format("Unable to update the password for user [%d], as its source is [%s].", user.getId(), user.getSource().toString()));
1532
+
thrownewInvalidParameterValueException("CloudStack does not support updating passwords for SAML or LDAP users. Please contact your cloud administrator for assistance.");
0 commit comments