Setting Up SSO for 2 different Salesforce Organization
Setting up Salesforce as an Identity Provider (ORG 1).
Org 1: Enable Identity Provider in Salesforce:
- Log in to your Salesforce org.
- Navigate to Setup > Identity > Identity Provider.
- Click Enable Identity Provider.
- Click Save
- Go to Remote Site Settings in ORG 2 (SP) > Click “New Remote Site Setting” and provide the necessary information.
- For the “Remote Site URL” on the picture above, go back to ORG 1 > Identity Provider. Now copy the Salesforce Identity URL Settings and paste it in the “Remote Site URL” in number 5 above.
- Go to setup > Identity > Single Sign on Settings.
- Click on “New from Metadata URL”
- Follow the example on number 6 above since we are using the same URL. Copy the URL and paste it as seen in the picture below and click on “Create”.
- Under the “SAML Identity type”, Select “Assertion contains the federation ID from the User Object”.
Back to ORG 1 (IDP)
Setting up the Connected App on Salesforce Org 1 (IDP)
- Go to setup
- Under Platform Tools tab, select Apps
- Click App Manager
- New Connected App
- Configure the Connected App:
- Under Web App Settings, Click on SAML checkbox and provide the required data. This will be used to establish the SSO.
- For the Entity ID Field and ACS URL, go to the ORG 2 (SP), under identity > Single Sign On, and copy the following URL as seen on the picture below. For Entity ID.
For ACS URL, Copy the Login URL
- For Subject Type, “Change Select type” and set to “Federation ID”
- Click Save
- Click on Manage.
- Scroll down to Profile section and Click on “Manage Profile” .
- Select a Profile to assign to the connected App. Checked System Administrator, then click Save. This will add the profile to the connected App.
- Go to ORG 2, Under setup, search for “My domain” scroll down to click on “Edit” under the “Authentication Configuration”.
- Check the second box. This is the 2 org you are using as the IDP.
- Click Save
- Go to Org 2, Under Setup > Users. Edit your username.
- Scroll down to “Single Sign on Information Section” and paste your Federation ID code. Note: Your federation ID should be unique e.g (crawlwise@gmail.com). This can be any attribute, as long as it is unique.
- To test your connection, go to ORG 1 (IDP) > App Manager > Scroll down and select the connected app you have created. From the dropdown option, select “Manage”.
- Scroll down and click on the Idp-initialted-login-url.
- This should log you in to the first org without any issues.
If you encounter any issues during the login process using the idp-initiated Login URL, please check through steps again to ensure everything is done correctly.
Contact Me:
Whatsapp Number: +2348078339783
Email Address: crawlwise@gmail.com
Linkedin Account: www.linkedin.com/in/albert-eromosele-47321370
Top comments (0)