A Salesforce account is automatically configured for single logout (SLO) when it is set up for Identity as a Service authentication. When the user logs out of a Salesforce Cloud account that is set up for Identity as a Service authentication, the user is also logged out of Identity as a Service. When the user logs out of Identity as a Service, the user is not automatically logged out of Salesforce Cloud.
You can also encrypt the assertions of this application.
Note: Entrust recommends using a Federation ID for the User ID of your Salesforce account. Modify the Username at Administration > Users > Users in your Salesforce account. When adding Salesforce to Identity as a Service, define a User Attribute that maps to the user ID settings in your Salesforce configuration.
Note: The instructions for this procedure apply to Salesforce Cloud accounts with the Lightning Experience user interface. You can follow the procedures if you have a Salesforce account with the classic user interface, but some of the steps may vary.
To integrate Salesforce with Identity as a Service you must do the following:
1. Click
> Members > Attributes. The User
Attributes List page appears.
2. Under
Custom User Attributes, click . The Add User Attribute
dialog box appears..
3. Enter Salesforce as the User Attribute Name for the custom user attribute.
4. Check Required to make the user attribute mandatory.
5. Click Add to create the attribute. The attribute now appears in the list of Custom User Attributes.
Create a custom domain
1. Log in to your Salesforce administrator account.
2. In
Salesforce, click the cogwheel ()
and select Setup. The Setup
Home navigation pane appears.
3. In the navigation pane, go to Settings > Company Settings > My Domain. The My Domain page appears.
4. In the Domain Name text box, enter a domain name.
Note: If you cannot create a new domain name for your Salesforce URL, it is because you (or someone else) has already created a domain name for this account.
5. Click Check Availability to confirm the availability of the domain name.
6. After you find an available domain name, click Register Domain.
You will receive a confirmation email when your domain is ready for testing.
Export a SAML signing certificate
1. Log in to your Identity as a Service administrator account.
1. Click
> Security > Applications.
The Applications List page appears.
2. Under SAML Cloud Integrations, click SAML Signing Certificates. The SAML Signing Certificates page appears.
3. Click
next to the certificate to export the certificate
you want to import into your SAML service provider application. The Export Certificate dialog box appears.
a. If the certificate has been issued by a CA, do one of the following:
– Click Certificate to export the self-signed certificate.
– Click Root CA Certificate to export a certificate issued from a CA.
– Click Certificate Chain to export the SAML signing certificate and its CA certificates.
b. Click Export.
Modify Salesforce settings to support encryption
1. Log in to your Salesforce administrator account.
2. Go to Settings > Security > Certificate and Key Management. The Certificate and Key Management page appears.
3. Click Create Self-Signed Certificate. The Certificates page appears.
4. Enter a Label for your Salesforce certificate.
5. Enter a Unique Name.
6. Click Save. You are returned to the Certificates page.
The newly-created certificate appears in the Certificates list.
7. Click the new Certificate. The Certificate and Key Details appear.
8. Click Download Certificate. The certificate is downloaded to your computer.
Configure Salesforce for SSO
1. In your Salesforce administrator account, go to Settings > Identity > Single Sign-On Settings. The Single Sign-On Settings page appears.
2. Under SAML Single Sign-On Settings, click New. The SAML Single Sign-On Settings page appears.
3. In the Name and API Name text box, enter the Domain Name you created in Step 1: Create a custom domain.
4. In the Issuer text box, enter the URL of your Identity as a Service account, followed by /api/saml
Example: https://example.us.trustedauth.com/api/saml
5. In the Entity ID text box, enter https://<domain name> where domain name is your Salesforce account domain name.
Example: https://example.my.salesforce.com.
6. In the Identity Provider Certificate field, browse to upload the signing certificate you downloaded from Identity as a Service in Step 3: Export the signing certificate from IDaaS.
7. From the Request Signing Certificate drop-down list, select the certificate you created in Step 4: Modify Salesforce to Support Encryption.
8. From the Request Signature Method drop-down list, select RSA SHA256.
9. From the Assertion Decryption Certificate drop-down list, select the certificate you created in Step 4: Modify Salesforce to Support Encryption.
10. Select the SAML Identity Type that you want use to authenticate from Identity as a Service to Salesforce. This is the method used to redirect Salesforce users to Identity as a Service for authentication. Select the assertion to contain one of the following:
● Select Assertion contains the User's Salesforce username to redirect a user to Identity as a Service based on the Salesforce attribute in Identity as a Service.
● Select Assertion contains the Federation ID from the User Object to redirect a user to Identity as a Service based on their Federation ID.
11. For the SAML Identity Location, select Identity is in the NameIdentifer element of the Subject statement.
12. For the Service Provider Initiated Request Binding, select HTTP Redirect or HTTP POST.
13. In the Identity Provider Login URL text box, enter the URL of your Identity as a Service account, followed by /api/saml/SAML2/SSO .
Example: https://example.us.trustedauth.com/api/saml/SAML2/SSO .
14. In the Custom Logout URL text box, enter https://<domain>/api/saml/SAML2/SLO where domain is your IDaaS domain.
Example: https://example.us.trustedauth.com/api/saml/SAML2/SLO
Setting the Custom Logout URL causes the user to log out of their Identity as a Service account when they log out of Salesforce.
15. Leave the Custom Error URL blank.
16. Confirm that Single Logout Enabled and Just-in-time User Provisioning are not selected.
17. Click Save. The settings are saved and the Endpoints appear on the Single Sign-On Settings page.
18. Record the Login URL and Logout URL in a separate location. You need to enter both of these URLs when you complete Step 7: Add Salesforce to Identity as a Service.
19. Under Settings > Identity, click Single Sign-On Settings to refresh the Single Sign-On Settings page.
20. Above Federated Single Sign-On Using SAML, click Edit.
21. Select SAML Enabled to enable Federated SSO.
22. Click Save.
Assign a Federation ID to users
1. In your Salesforce administrator account, go to Administration > Users > Users. The All Users page appears.
2. Click the user name. The User Detail page appears.
3. Click Edit. the General Information page appear.
4. Under Single Sign On Information, enter a value for the Federation ID that corresponds to the Identity as a Service user attribute you created in Step 1: Create a custom user attribute for Salesforce.
5. Click Save.
Click
here if you selected Assertion contains the User's
Salesforce username
To redirect users to Identity as a Service
1. In your Salesforce administrator account, do the following:
2. Go to Settings > Company Settings > My Domain. The My Domain page appears.
3. Scroll to the Authentication Configuration section and click Edit.
4. Click Edit. The Authentication Configuration page appears.
3. Under Authentication Service, do the following to have your Salesforce users redirected automatically to Identity as a Service for authentication:
a. Deselect Login Page.
b. Select your SAML configuration.
4. Click Save to return to the My Domain page.
5. Deploy the configuration to users, as follows:
a. Click Deploy to Users. A Click OK on the warning message.
b. Click Edit in the My Domain Settings section of the My Domain page.
c. Select Prevent login from https://login.salesforce.com.
d. Click Save.
The My Domain Settings shows that the Login Policy is enabled to prevent users from logging into Salesforce directly.
Add the Salesforce application to Identity as a Service
1. Log in to your Identity as a Service administrator account.
2. Click
> Security > Applications. The Applications
Lists page appears.
3. Click Add. The Select an Application Template page appears.
4. Under SAML Cloud Integrations, click Salesforce. The Add Salesforce page appears.
5. Enter an Application Name.
6. Enter an Application Description.
7. Optional. Add a custom application logo.
a. Click next to Application Logo. The
Upload Logo dialog box appears.
b. Click to
select an image file to upload.
c. Browse to select your file and click Open. The Upload Logo dialog box reappears showing your selected image.
d. If required, resize your image.
e. Click OK.
8. Select the Authentication Flow that appears to users during login.
9. Click Next. The General setup page appears.
10. If available, use the Upload Metadata XML file option to auto-populate the following fields, if available in the file:
● Default Assertion Consumer Service URL
● Alternative Assertion Consumer URLs
● Service Provider Entity ID (Issuer)
● Single Logout Service URL
● SAML Signing Certificate
● SAML NameID Encoding Format
● SAML Signature Algorithm
11. To import the Metadata file:
a. Click and browse
to select the file. The Metadata
Configuration dialog box appears.
b. If required, click Merge with existing values to merge new values with existing values for Alternative Assertion Consumer Services URLs and SAML attribute names.
c. Click Save.
12. If you do not have a metadata file, use the information provided in the next steps to populate the fields.
a. Enter the Default Assertion Consumer Service URL.
The SAML Assertion Consumer Service URL is the URL used by Identity as a Service to assert authentication to an application. In Salesforce, this is the Salesforce Login URL provided on the SAML Single Sign-On Settings of your Salesforce account. You made note of this URL in Step 5: Configure Salesforce for SSO.
b. Enter the Service Provider Entity ID (Issuer), which is used by Identity as a Service to identify the application. The entity URL must be unique and in standard URI format.
Tip: In your Salesforce administrator account, go to Settings > Identity > Single Sign-On Settings. Your Entity ID is shown on the Single Sign-On Settings page.
13. Enter the SAML Session Timeout to the time when the SAML Assertion times out. The maximum is 720 minutes.
14. Enter the Max Authentication Age (seconds) to set the maximum amount of time that can elapse before a user is required to reauthenticate during a new login attempt. This applies for both SP-initiated and IDP-initiated login. Set this field to -1 to disable this feature.
15. From the SAML NameID Attribute, select the following:
a. The SAML NameID Attribute must contain a user name if Username was selected as the SAML Identity Type in Step 5: Configure Salesforce for SSO.
b. The SAML NameID Attribute must contain a Federation ID if Federation ID was selected as the SAML Identity Type in Step 5: Configure Salesforce for SSO.
c. The user attribute value selected as the SAML NameID Attribute must contain a user name or Federation ID that already exists in your Salesforce account.
Attention: Make sure that the SAML NameID Attribute you select corresponds to a Username or Federation ID already registered in your Salesforce account. Check that the spelling and case of every character of the SAML NameID Attribute is an exact match. If one letter is entered incorrectly, the user will not be able to log into the application. If a user does not enter a user name or Federation ID registered on the Salesforce account, authentication to the applications fails. You can add an additional user attribute containing a valid user name or Federation ID. For assistance doing so, see Add a user attribute.
16. Leave the Single Logout Service URL field blank.
Note: Users that log out from Salesforce are redirected to the Identity as a Service login page.
17. Optional. Enter the SAML Username Parameter Name used to identity the user ID being requested for authentication. The user ID can then be passed as a parameter, for example, Username=jdoe. Alternately, if the SAML username is NameID, the SAML Request XML NameID element value is used to the identify the IDaaS userID.
18. Select the SAML NameID Encoding Format from the drop-down list.
Note: Make sure that the SAML NameID encoding format corresponds with the type of SAML NameID Attribute you have selected. If the attribute contains an email address, select Email_ID. If it contains a standard username or Federation ID, select Unspecified or Persistent.
19. Select the SAML Signing Certificate from the drop-down list.
20. From the SAML Response Signature Algorithm drop-down list, select the type of signing algorithm used by Identity as a Service to sign the SAML response.
21. Optional: Select Sign complete SAML response to ensure the message integrity of the SAML response sent to Salesforce during authentication.
22. Deselect Enable Go Back Button if you do not want users to be able to go back to the Salesforce login page to log in.
23. Select Show Default Assertion Consumer URL Service in the My Profile. When selected, the Default Assertion Consumer URL appears in a user's My Profile page in addition to relay states and Alternative Assertion Consumer URLs.
24. Optional. Select Encrypt SAML Assertion to secure communications between Identity as a Service and Salesforce.
a. From the Encryption Method for Key drop-down list, select either RSA Version 1.5 or RSA-OAEP. RSA Version 1.5 is the default.
b. From the Encryption Method for Data drop-down list, select the encryption method used to encrypt data.
c. In the Encryption Certificate field, upload the encryption certificate file you downloaded in Step 3:Modify Salesforce account settings to support encryption.
Note: The Subject Domain Name and Certificate Expiry Date values are populated with values from the certificate once the Encryption Certificate is uploaded.
25. Optional. Add Alternative Assertion Consumer Service URLs, as follows:
a. Click Add.
b. Enter a Name.
c. Enter a URL Value.
d. Select Show in My Profile to display the Alternative Consumer Service URL in a user's My profile page.
e. Optional. Add an Application Logo.
f. Click Add.
g. Repeat these steps to add more Alternative Assertion Consumer Service URLs.
26. Optional. Add a Relay State as follows:
a. Under Relay State, click Add. The Add Relay State dialog box appears.
b. Enter a Name for the relay state.
c. Enter the Value for the relay state. This setting specifies the application or URL that is a user is redirected to after successful authentication.
d. Select Show in My Profile to display the relay state on the user's My Profile page.
Note: After
you add relay states, you can also enable or disable them on the Add/Edit
application page. Click
next to the relay state to disable it or click
to re-enable it.
Relay states apply to the Default Assertion Consumer Service URLs and
not the Alternative Assertion Consumers URLs.
e. Optional.
Add a Relay State custom logo.
Click next
to Relay State Logo. The Upload
Logo dialog box appears.
Click
to select an image file to upload.
Browse to select your file and click Open. The Upload Logo dialog box reappears showing your selected image.
If required, resize your image.
Click OK.
f. Click Add.
g. Repeat these steps to add more Relay States.
27. Click Submit.
Create a resource rule to protect access to a SAML application
1. Log in to your Identity as a Service administrator account.
2. Click
> Security
> Resource Rules. The Resource Rules List
page appears.
3. Click + next to the application you want to protect with a resource rule. The Add Resource Rules page appears.
4. Enter a Rule Name and Rule Description for the resource rule.
5. In the Groups list, select the group or groups of users restricted by the resource rule.
These are the groups to which the resource rule applies. If you do not select any groups, by default the resource rule applies to all groups.
6. Click Next. The Authentication Conditions Settings page appears.
7. Optional: Select Disable Single Sign-On for Application to force a user to re-authenticate whenever they attempt a new login.
8. If you do not Enable Advanced Risk Factors, do the following:
a. Select the Authentication Flow from the drop-down list. The Authentication Flow flowchart updates based on the selection.
b. Click Submit to save the Resource Rule.
9. If you want to Enable Advanced Risk Factors, complete the remaining steps in this procedure.
10. Select Enable Advanced Risk Factors to add additional risk factors to the resource rule.
11. Select Enable Strict Access for Application to set the resource rule to deny access regardless of the outcome from other resource rules. If this option is disabled for any resource rule that denies access, the user is allowed access if at least one resource rule allows access.
12. For each Advanced Risk Factor, click the Deny option to deny access to the application if the risk factor fails regardless of the results of the other risk factors.
13. Click Date/Time to set the conditions as follows:
a. Select one of the following:
– Allow Date/Time to set when a user can access the application.
– Deny Date/Time to set when the user cannot access the application.
The Date/Time Context Condition Settings appear.
b. Select the Condition Type:
– Specific Date Range Condition—Allows or denies access to the application during a select period of days.
– Time-of-day and/or Day of Week Recurring Conditions—Allows or denies access to the application on a specific time of day, day of the week, or both. Recurring times selected only apply to days not denied.
– Clear Selection—Clears existing Date and Time conditions.
c. Set the Condition Type settings, as follows:
i) Select Use local time zone to use the local time zone or deselect Use local time zone to use the local time zone and begin typing the time zone in the Begin Typing Timezone name field and select the time zone from the drop-down list.
ii) If you selected Specific Date Range Condition, click Start Date to select a start date from the pop-up calendar. Optionally, select the End Date.
iii) If you selected Time-of-Day and/or Day-of-Week, click Start Time and select the start time from the pop-up clock. Optionally set the End Time. You must also select the days of the week for the condition.
d. Click Save to return to the Authentication Conditions Settings page.
14. Click Geolocation to set the Location Condition Settings, as follows:
a. Select Allow or Deny to create an allowed or denied country list.
b. From the Selected Countries drop-down list, select the countries to add or deny access to the application. Repeat until you have added all the desired countries to the list.
c. Select Allow Anonymous IP Address to increase the risk of users authenticating from an anonymous IP.
d. Click Save to save to return to the Authentication Conditions Settings page.
15. Click Source IP Address. The IP Address Risk Setting dialog box appears. Do one of the following:
a. Select Custom and add the required IP Allowed Addresses and IP Denied Addresses.
b. Select IP List Address and select the IP List to allow or deny.
c. Select None to not restrict any IP addresses.
d. Click OK to return to the Authentication Conditions Settings.
16. Click Machine Authentication to set the Machine Authentication Condition Settings, as follows:
a. Set the Machine Authentication Risk is less than or equal to the value that the machine authenticator's total risk score must be less than during authentication to pass this condition.
The risk score is based on the attribute differences
between a user's Machine Authentication information and that recorded
on Identity as a Service before the condition fails. If an attribute does
not match, the attribute incurs the number of risk points shown in Non-Matching Risk Points for that attribute. The
Non-Matching Risk Points values of each non-matching
attribute are added together, resulting in a total risk score. This score
is normalized to be out of 100 as follows:
Total Risk Score = (Total Risk Points
of Failing Attributes / Maximum Risk Points of All Enabled Attributes)
* 100
The resource rule condition fails when the number of non-matching risk
points exceeds the Machine Authentication Risk value defined in this step.
A value of 0 means that a single attribute
difference causes the Device Fingerprint
condition to fail. The default value is 3.
The value between 0-50 can be entered.
The default value is defined by the Machine Risk Limit.
See Modify machine authenticator settings.
b. Click Save.
17. Define the Location History / Known Locations and Travel Velocity conditions. The Risk-Based Authentication (RBA) settings of your Identity as a Service account define the location history and travel velocity conditions. See Manage risk-based authentication settings for more information.
18. Set the Device Certificates risk factor to require the client to perform client-authenticated SSL with a certificate issued from a trusted CA to pass.
19. Set the risk score for application conditions to set the risk percentage a user receives if they fail to meet the condition, as follows:
● Click the dot next to the condition setting and slide the risk scale to the risk percentage
-or-
● Click the 0% and enter the risk points and then click OK.
The default setting is 0%. The Risk percentage determines the authentication requirements as set by the Authentication Decision. When a user attempts to authenticate to an application, the final risk percentage is the sum of all failed conditions.
20. Set the Authentication Decision risk level for Medium Risk and High Risk as follows:
a. Click the risk threshold percentage to the right of Medium Risk or High Risk. The Risk Threshold dialog box appears.
b. Enter the risk percentage.
c. Click OK.
21. Select the Authentication Flows for Low Risk, Medium Risk, and High Risk from the drop-down lists. The Authentication Flows flowchart updates based on your selections.
22. Click Submit to create the resource rule.