throw new RemoteException(msg);
}
// Obtain the back-end server URL from the request. If not obtain it
// from the http session and then from the ServletContext.
AuthenticationAdminClient proxy = getAuthenticationAdminCient(request);
String userNameWithDomain = userName;
String domainName = (String) request.getAttribute(MultitenantConstants.TENANT_DOMAIN);
if (domainName != null) {
userNameWithDomain += "@" + domainName;
}
userNameWithDomain = userNameWithDomain.trim();
boolean isLogged = false;
if (isRememberMe) {
RememberMeData data = proxy.loginWithRememberMeOption(userNameWithDomain, password,
request.getRemoteAddr());
if (data != null) {
isLogged = true;
request.setAttribute(CarbonConstants.REMEMBER_ME_COOKIE_VALUE, data.getValue());
request.setAttribute(CarbonConstants.REMEMBER_ME_COOKIE_AGE,
new Integer(data.getMaxAge()).toString());
}
} else {
isLogged = proxy.login(userNameWithDomain, password, request.getRemoteAddr());
}
return isLogged;
} catch (AxisFault axisFault) {
throw axisFault;
} catch (RemoteException e) {