mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
Merge release branch 4.9 to master
* 4.9: Bug-ID:CLOUDSTACK-9369 Fixed Ldap regression
This commit is contained in:
commit
38f1050ff8
@ -166,7 +166,7 @@ public class DefaultLoginAPIAuthenticatorCmd extends BaseCmd implements APIAuthe
|
||||
throw new CloudAuthenticationException("Unable to find the domain from the path " + domain);
|
||||
}
|
||||
final UserAccount userAccount = _accountService.getActiveUserAccount(username[0], domainId);
|
||||
if (userAccount == null || !(User.Source.UNKNOWN.equals(userAccount.getSource()) || User.Source.LDAP.equals(userAccount.getSource()))) {
|
||||
if (userAccount != null && User.Source.SAML2 == userAccount.getSource()) {
|
||||
throw new CloudAuthenticationException("User is not allowed CloudStack login");
|
||||
}
|
||||
return ApiResponseSerializer.toSerializedString(_apiServer.loginUser(session, username[0], pwd, domainId, domain, remoteAddress, params),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user