Connecting an LDAP Gateway service
Connect PingOne Authorize to an LDAP gateway service to access user information stored in an external, on-premise LDAP directory, such as PingDirectory or Microsoft Active Directory.
An LDAP gateway setup has two parts:
-
An LDAP gateway connection in PingOne, and at least one gateway instance running on-premise. The gateway allows PingOne to communicate with the directory.
-
An LDAP Gateway service connection in PingOne Authorize. The service connection references the gateway, and PingOne Authorize uses it to retrieve identity data from the directory for use in authorization policies.
|
Only LDAP gateway connections are supported. You can’t connect to other gateway types, such as RADIUS Gateway. |
PingOne Authorize converts user information retrieved from an LDAP gateway service to JSON. The following is an example response from an LDAP gateway service connection:
{
"entries": [
{
"_dn": ["cn=Philip J. Wilson,ou=people,dc=example,dc=com"],
"objectClass": ["inetOrgPerson","organizationalPerson","person","top"],
"cn": ["Philip J. Wilson"],
"sn": ["Wilson"],
"description": ["Human"],
"displayName": ["Wilson"],
"employeeType": ["Loan Officer"],
"givenName": ["Philip"],
"mail": ["wilson@example.com"],
"ou": ["Commercial Banking"],
"uid": ["wilson"],
"userPassword": ["xx"],
"entryDN": ["cn=philip j. wilson,ou=people,dc=example,dc=com"],
"entryUUID": ["3d7d9bfa-4d85-4414-94bc-ed9cfbe717b9"],
"subschemaSubentry": ["cn=schema"],
"creatorsName": ["cn=Internal Root User"],
"createTimestamp": ["20230516132411.457Z"],
"modifiersName": ["cn=Internal Root User"],
"modifyTimestamp": ["20230516132411.457Z"]
}
]
}
You can use JSON Path processors in attributes to extract the information that you require from the service response for use in authorization policies.
Steps
-
Set up an LDAP gateway in PingOne, including at least one running gateway instance. Learn more in Setting up an LDAP gateway.
-
In the PingOne admin console, go to Authorization > Trust Framework.
-
In the Module list, select the module in which you want to add the service.
-
For the Service Type, select LDAP Gateway.
-
For Gateway, select the LDAP gateway connection that you set up in PingOne.
-
For the Search Base DN, enter the distinguished name for the directory information tree location where you want PingOne Authorize to start looking for user information.
Example:
The search base in the following is the domain component example.com:
dc=example,dc=com
-
To limit the scope of the results returned from the LDAP directory, enter a Filter.
Example:
The following filter returns users that have email addresses, but aren’t administrators:
(&(objectClass=person)(mail=*)(!(employeeType=Admin)))
-
Finish configuring general settings for the service.
Next steps
-
Test the service connection to verify that PingOne Authorize can connect to the LDAP gateway and retrieve user information.
-
Add attributes that extract information from the service response for use in authorization policies.
Example: Retrieve user profile information
The following attribute extracts user email addresses from a PingDirectory service. The JSON Path expression $.entries[*].mail[0] returns an array of mail strings, such as ["wilson@example.com"].
Example: Retrieve user groups
To retrieve a user’s group memberships:
-
Set the Search Base DN for the LDAP gateway service to
ou=groups,dc=example,dc=com. -
Enter a Filter to retrieve a list of groups for a particular user, such as Philip Wilson.
The following filter returns a list of the static groups to which Philip Wilson belongs:
(|(member=uid=wilson,ou=users,dc=example,dc=com)(uniqueMember=uid=wilson,ou=users,dc=example,dc=com))
To retrieve all the users that belong to a particular group, such as loan officers, enter the following settings for the LDAP gateway service:
-
Search Base DN:
ou=people,dc=example,dc=com -
Filter:
(isMemberOf=cn=loanAdmin,ou=groups,dc=example,dc=com)
To check whether a specific user is a member of a particular group, such as loan officers, enter the following settings for the LDAP gateway service:
-
Search Base DN:
uid=wilson,ou=people,dc=example,dc=com -
Filter:
(isMemberOf=cn=loanAdmin,ou=groups,dc=example,dc=com)