These steps show you how to configure the single sign-on (SSO) functionality using OpenID Connect between ManageEngine ADSelfService Plus and Salesforce.
global class ADSSPOIDCHandler implements Auth.RegistrationHandler{
global User createUser(Id portalId, Auth.UserData data){
User u = new User();
String username = data.email;
Profile p = [SELECT Id FROM profile WHERE name='Standard User'];
u.email = data.email;
u.lastName = data.lastName;
u.firstName = data.firstName;
String alias = data.username;
if(alias.length() > 8) {
alias = alias.substring(0, 8);
}
u.alias = alias;
u.username =username;
u.languagelocalekey = UserInfo.getLocale();
u.localesidkey = UserInfo.getLocale();
u.emailEncodingKey = 'UTF-8';
u.timeZoneSidKey = 'America/Los_Angeles';
u.profileId = p.Id;
return u;
}
global void updateUser(Id userId, Id portalId, Auth.UserData data){
User u = new User(id=userId);
update(u);
}
}
Your request has been submitted to the ADSelfService Plus technical support team. Our technical support people will assist you at the earliest.
Copyright © 2024, ZOHO Corp. All Rights Reserved.