You can configure ForgeRock to use Identity as a Service for multi-factor authentication.
Tip: When performing this integration, you copy and paste content from one application to the other. Open ForgeRock in one browser window and Identity as a Service in another to make copying and pasting easier.
To integrate ForgeRock OIDC with Identity as a Service, complete the following steps:
1. Log in to ForgeRock Access Manager.
2. Click Top Level Realm. The Realm Overview page appears.
3. In the navigation pane, click Authentication > Trees. The Trees page appears.
4. Click Create Tree.
5. Enter a Tree Name and click Create. A blank tree appears that you can customize.
6. Under Components, click and drag the following nodes to the tree:
● Success
● OpenID Connect
● Provision Dynamic Account
Note: Depending on where you store your users, you might use Provision IDM Account instead of Provision Dynamic Account.
7. Remove
the Failure node by selecting it and then
clicking .
8. Wire the nodes as shown in this diagram. To wire them, click the red dot and drag to connect it to the connecting dot. The red dots change to green when they are connected.
9. Click the OpenID Connect node to open the OpenID Connect dialog box.
10. Scroll down to Redirect URL and copy the value. You need to paste this URL into Identity as a Service.
11. Leave OpenID Connect dialog box open as you will need to copy values from Identity as a Service into this dialog box.
1. Log in to Identity as a Service.
2. Click
> Security > Applications. The Applications
List page appears.
3. Click Add. The Select an Application Template page appears.
4. Under OpenID Connect and OAuth Cloud Integrations, click ForgeRock OIDC. The Add ForgeRock OIDC page appears.
5. Modify the Application Name and Application Description, if required.
6. Optional. Add a custom application logo, as follows:
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.
7. Select the Authentication Flow that appears to users during login.
8. Click Next. The Settings page appears.
9. In the General Settings, do the following:
a. Click
to copy the Client ID is generated
when you create the application on Identity as a Service. You cannot
modify the Client ID. You can then paste the Client
ID value into the required field of your client ForgeRock OIDC
application account settings.
b. Click to copy the Client Secret value. You can then
paste the Client Secret value
into the required field of your client ForgeRock OIDC application
account settings.
Note: You can define your own Client Secret value. However, Entrust recommends that you use the strong secret value provided.
c. Select the OIDC Signing Certificate used to connect to ForgeRock.
d. Optional: Enter the Initiate Login URI to allow users to access the application from Identity as a Service.
The Login URI is the location from which authentication to the ForgeRock OIDC application through Identity as a Service can be initiated.
e. Click Add to add a Login Redirect URI.
The URI is the location a user is redirected to after being provided or denied access to the ForgeRock OIDC. The value can be a URL, and you can add more than one value.
Note: The login redirect URI hostname is added as a valid CORS origin for OIDC processing.
10. Deselect Enable Go Back Button if you do not want users to be able to go back to the ForgeRock login page to log in.
11. In the Authentication Settings, do the following:
a. Select Require Content to require that users respond to a consent prompt for each request.
b. Optional. Enter a Consent Message to include a message to users when consent is requested.
c. Set Max Authentication Age (seconds) to the maximum amount of time that can elapse before a user must re-authenticate to log in. This feature is disabled if the field is left blank.
d. Under Grant Types, select Authorization Code. The Grant Type tells Identity as a Service what flow to use for returning authorization responses.
e. From the Authorization Code PKCE Code Challenge Method drop-down list, select S256 as the method used with PKCE during authentication.
f. Select Include Authentication Time to include the authentication time for ID tokens.
g. From the ID Token Signing Algorithm drop-down list, select RS256 as the signing algorithm used to sign with ID Token during authentication.
h. From the User Info Signing Algorithm, select none.
12. The authorization request uses Supported Scopes to establish a connection between Identity as a Service and the ForgeRock OIDC application. Supported Scopes are selected by default. If you disable Your unique identifier, the ForgeRock OIDC application strictly uses an access token to access a resource server API on behalf of a user.
Note: Click the arrow next to each scope to see the list of Implied Claims included in the scope. The list of Implied Claims is defined by OpenID Connect and cannot be modified. Every Implied Claim included in the scopes you select under Supported Scopes should have an associated Identity as a Service user attribute so that the attribute is returned as part of the OIDC tokens sent back to the client. For example, if you select Address as a Supported Scope, then you must define an Identity as a Service user attribute for each Implied Claim associated with Address. See Create and manage user attributes.
13. If required, add additional Supported Claims to map OIDC claims to Identity as a Service user attributes.
The supported claims define the claims that are requested by the client during an authorization request. A claim is an Identity as a Service user attribute, for example, first name. The user attribute must be included if that claim is requested by the client during an authorization request. The required claims depend on the OIDC application that you are configuring on Identity as a Service.
You can group claims, for example, the default claim, name, includes the user attribute First Name, a text-based value of a space and the user attribute value of Last Name so that the claim returned to the client is First Name <space> Last Name, for example Alice Gray.
14. To add a claim:
a. Ensure that you have already created the required User Attributes in Identity as a Service (see Create and manage user attributes).
a. Click . The Add
Claim dialog box appears.
b. In the Claim Name field, do one of the following:
i) Select the Claim Name from the drop-down list.
-OR-
ii) Type a Claim Name to create a new custom claim.
c. In the Enter the Claim value expected by the Service Provider field, enter the following, as required:
– User Attribute Value—An Identity as a Service user attribute (see Create and manage user attributes)
– Text Based Value—A text based value. For example, to add a space between two claims or add text information.
– Related Value—Include user group or authenticator attributes. See Configure OIDC claim to include user authenticators or groups.
Example: some text <first Name> <Last Name> [Groups]
d. Select Always Return with User Info to always return the user information with the claim.
e. Select Always Return with ID Token to always return the ID Token with the claim.
f. Click Add.
Note: If
required, click
next to the claim and make the required changes. Click
to delete a claim.
15. Click Submit.
Create a resource rule to protect access to OIDC applications
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.
1. In ForgeRock, open the OIDC Connect dialog box.
2. In the OIDC Connect dialog box enter the Client ID and Client Secret as follows:
a. In Identity as a Service,
click >
Resources > Applications. The Applications
List page appears.
b. Click ForgeRock OIDC. The Edit ForgeRock OIDC page appears.
c. Click Next to go to the ForgeRock OIDC General Settings in Identity as a Service. Keep this page open.
3. Go to ForgeRock and in the ForgeRock OIDC Connect dialog box, paste the following from Identity as a Service:
a. In the Client ID field, paste the Identity as a Service client ID.
b. In the Client Secret field, paste the Identity as a Service client secret.
4. Return to the Edit ForgeRock OIDC page in Identity as a Service and click Cancel to close the page. You are returned to the Applications List page.
5. In the Identity as a Service Applications List page, under ForgeRock OIDC application, click OIDC Configuration. The OIDC Configuration page appears.
6. Leave the OIDC Configuration page open as you need to copy information from this page to ForgeRock OIDC Connect dialog box.
7. Paste the following from the Identity as a Service OIDC Configuration into the ForgeRock OpenID Connect dialog box:
a. In the Authentication Endpoint URL, enter the Authorization Endpoint from Identity as a Service.
b. In the Access Token Endpoint field, enter the Token Endpoint from Identity as a Service.
c. In the User Profile Service URL, enter the Userinfo Endpoint from Identity as a Service.
8. Leave the Identity as a Service OIDC Configuration page open as you will need to return to it later in this procedure.
9. In the ForgeRock OIDC Connect dialog box, do the following:
a. In the OAuth Scope field, change the scope to match the Identity as a Service configuration, for example, openid, profile, or email. If you want to use more than one, enter each one in the field separated by a space. For example: openid profile email
b. Enter a name for the Social Provider, for example, Identity as a Service.
10. Update the ForgeRock mappers as follows (delete any existing values and replace them with the new values):
Note: This configuration is valid for an out of the box ForgeRock AM backed by a local embedded directory. Your mappings may require changes depending on your setup.
a. In the Account Mapper field, enter:
org.forgerock.openam.authentication.modules.common.mapping.JsonAttributeMapper|*|Identity as a Service-
b. In the Attribute Mapper field, click x to delete the existing entry and then add the following enter the new Attribute Mapper and press Enter.
org.forgerock.openam.authentication.modules.common.mapping.JsonAttributeMapper|uid|Identity as a Service-.
c. In the Account Mapper Configuration, delete the existing sub key (if one exists) and then click Add.
d. Add the following key and value.
– sub = uid
e. Click + after entering the key and value.
f. In the Attribute Mapper Configuration, delete the existing sub key (if one exists) click Add and the following keys and values.
You must click + after entering each key and value pair to add it to the Attribute Mapper configuration.
– sub = uid
– name = cn
– given_name = givenName
– family_name = sn
– email = mail
11. Return to the Identity as a Service OIDC Connection page.
12. Paste the following from the Identity as a Service OIDC Configuration into the ForgeRock OpenID Connect dialog box:
a. In the Token Issuer field, enter the Issuer from Identity as a Service.
b. In the OpenID Connect Validation Value field, enter the Openid Configuration from Identity as a Service.
c. Click OK to close the Identity as a Service OIDC Configuration page.
13. Click Save to save the Identity as a Service mapping tree in ForgeRock.
1. Log out of both Identity as a Service and ForgeRock.
2. Open your ForgeRock OIDC instance using the new authentication tree, for example:
https://forgerockserver>.com:8443/openam/?service=Identity as a Service (where service=<tree name>)
3. You are redirected to Identity as a Service for authentication.
Upon successful authentication, you are logged in to ForgeRock.