Configuring LDAP connection
Configure an LDAP (Lightweight Directory Access Protocol) connection for your product cluster.
You must connect an LDAP directory with your product cluster. You can then add users from your LDAP directory into your cluster.
IM supports the LDAPEntityType configuration for
LDAP User and Group entities as default to define the
ObjectClass or ObjectCategory attributes
automatically in the Liberty XML file. The ObjectClass
or ObjectCategory attributes of the User and Group are
retrieved from the User and Filter fields
that are defined in the LDAP IDP V3 idsource API. For existing LDAP
connection, you need to restart the
platform-auth-service pods to enable the
LDAPEntityType configuration. For more information,
see Enabling LDAPEntityType
configuration for existing LDAP User and Group entities.
The following LDAP types are supported:
- PingDirectory Server
- IBM Tivoli Directory Server
- IBM Lotus Domino
- IBM SecureWay Directory Server
- Novell eDirectory
- Sun Java™ System Directory Server
- Netscape Directory Server
- Microsoft Active Directory
- Custom
ibm-platformui-operator) service is installed, user
management capabilities are available for managing LDAP user and
user groups roles, and permissions. You can add an LDAP or
OpenShift user to your cluster. When you add a user, you must
specify the OpenShift or LDAP login ID of the user in the
Username field.Required user type or access level: Cluster administrator or Cloud Pak administrator
Enabling LDAPEntityType configuration
for existing LDAP User and Group entities
Restart the platform-auth-service pods to enable
the LDAPEntityType configuration for the existing LDAP
connection.
-
Get the
platform-auth-servicepod name.oc get pods -n <your-foundational-services-namespace> | grep platform-auth-service -
Delete the
platform-auth-servicepod.oc delete pod <platform-auth-service> -n <your-foundational-services-namespace>
The procedure is not applicable for new LDAP connection.
Connecting to your LDAP directory
Follow these steps to set up your LDAP connection.
Pre-requisite: Install the cluster. Once the cluster is installed, the admin username, password, and the URL are displayed.
-
Log on to the console by using the URL and enter the username and password.
Note: The console can be Platform UI or Common UI. For more information, see Accessing your cluster by using the console . -
From the navigation menu, click Identity and access > Identity providers.
-
Click Create Connection. The "LDAP connection" page is displayed.
-
Enter the following details to set up your LDAP connection.
Note: You can configure multiple LDAP connection instances to the same LDAP server. However, ensure that you meet the following requirements:- Both the
Base DNand connectionNamemust be unique. - The username from the LDAP attribute that you specified in the
User ID mapmust be unique across your LDAP instances. This requirement is because WebSphere Liberty uses federated registries for the multiple LDAPs by default. For more information, see Configuring LDAP user registries in Liberty. -
IBM Cloud Pak foundational services provides a default
adminuser ID. If your LDAP registries haveadminuser IDs, you must rename the defaultadminuser ID that foundational services provides. For more information about how to change the default name, see Changing the default admin username or Changing the cluster administrator username.
LDAP connection
Enter connection information.
-
Connection name: A unique name for the LDAP connection. Format: 3 - 30 alphanumeric characters; Special characters that are allowed:
-_ -
Server type: A list of directory server types to which you can connect. Select one from the list.
-
Case insensitive user search: Set the value to
trueorfalseto enable or disable case sensistivity for the LDAP usernames.
LDAP authentication
Enter authentication information.
-
Base DN: The distinguished name of the search base.
Example: dc=abc,dc=com
Format: 1 to 255 alphanumeric characters.
These special characters are allowed:=.,-
-
Bind DN: The user who is allowed to search the base DN.
Example: cn=admin,dc=abc,dc=com
This parameter is optional. If specified, the
Bind DN passwordparameter must also be specified. If no user is specified in theBind DNparameter, the LDAP connection is established without authentication.Format: 0 to 255 alphanumeric characters. White space is allowed.
These special characters are allowed:
=.,-:@()_\&
-
Bind DN password: The password of the user specified in the
Bind DNparameter. This parameter is required if a user is specified inBind DN. A maximum of 255 characters are allowed. Only ASCII characters are allowed; non-ASCII characters are not supported.Note: The configuration of Base DN and Bind DN values must be set as case-sensitive and must be a full distinguished name (DN) path. The DN path, including spaces, commas, and other characters, must be the same as configured in the LDAP server. See the following example:Base DN : DC=mycompany,DC=com Bind DN : CN=Administrator,CN=Users,DC=mycompany,DC=comFor
Base DN, the following values are invalid:- dc=mycompany,dc=com because
DCis lowercase alphabet. - DC=mycompany, DC=com because there is a space between the parameters.
For
Bind DN, the following values are invalid:- cn=Administrator,cn=Users,dc=mycompany,dc=com because
CNandDCare lowercase alphabets. - CN=Administrator,DC=mycompany,DC=com because
CN=Usersparameter is missing. - CN=Administrator,CN=Users, DC=mycompany,DC=com because there is a space between the parameters.
- CN=administrator,CN=Users,DC=mycompany,DC=com because the
administratorparameter value starts with a lowercase alphabet.
Note: Microsoft Active Directory server does a strict check ofBase DNandBind DNvalues while it establishes a connection. - dc=mycompany,dc=com because
You can click Test connection to verify whether the LDAP connection details are valid.
LDAP server
Enter the server URL for your connection.
-
URL: The LDAP directory domain name or IP
address, and the LDAP port number. The domain name must begin with
ldap(s)://. Example URL:ldap(s)://corpldap.abc.com:389orldap://10.10.10.1:389.
For LDAP over SSL (LDAPS), you must use the domain name, and the URL must begin with
ldaps://. Example URL:ldaps://corpldap.abc.com:636.Note: If you are unable to connect to your LDAPS server by using the host name, add the IP address and host name of the LDAPS server in your local DNS. The LDAPS server host name must be resolvable from your master node.LDAP filters
Note:
-
If your LDAP server is compliant with LDAP version 3, then the filters are not sensitive to alphabet case or to white spaces.
-
From foundational services version 3.19 and later,
Group filterandGroup member ID mapfilters support one or more than one value.
Enter information about the search filters. For default LDAP filters by LDAP type, see Default LDAP filters by LDAP type.
-
Group filter: The filter clause for searching groups. From foundational services version 3.23 and later, IM supports all the special characters but following are the validated and tested special characters: white space,
=;.,&%(){}<>|! -
Group ID map: The filter to map a group name to an LDAP entry. Format: 1 - 255 alphanumeric characters; Special characters that are allowed: white space,
*:=;.,&%(){} -
Group member ID map: The filter to map a user to a group. Format: 1 - 255 alphanumeric characters; Special characters that are allowed: white space,
*:=;.,&%(){} -
User filter: The filter clause for searching users. From foundational services version 3.23 and later, IM supports all the special characters but following are the validated and tested special characters: white space,
=;.,&%(){}<>|! -
User ID map: The filter to map a username to an LDAP entry. Format: 1 - 255 alphanumeric characters; Special characters that are allowed: white space,
*:=;.,&%(){}
- Both the
- Click Create.
Your cluster is now connected with your LDAP directory.
If your LDAPS connection is not successful, you can try setting up the connection manually. For more information, see Configuring LDAP over SSL.
Next, you can add your LDAP users and user groups to your cluster.
Default LDAP filters by LDAP type
userFilter and groupFilter
fields must contain an attribute with =%v value. For
example, (cn=%v) for Cloud Pak and Cloud Pak for data
login flow to work.The following table represents the name of the filters, their data types and their
default values. The groupFilter and groupMemberIdMap can have one
or more than one default value from foundational services version 3.19 and
later.
For example:
-
groupFilter= (&(cn=%v)((objectclass=groupOfNames)(objectclass=groupOfUniqueNames))) -
groupMemberIdMap= groupOfNames:member;groupOfUniqueNames:uniqueMember
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectclass=groupOfUniqueNames)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | groupOfUniqueNames:uniquemember |
| userFilter | String | (&(emailAddress=%v)(objectclass=person)) |
| userIdMap | String | *:emailAddress |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectclass=groupOfUniqueNames)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | groupOfUniqueNames:uniquemember |
| userFilter | String | (&(uid=%v)(objectclass=ePerson)) |
| userIdMap | String | *:uid |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectcategory=group)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | memberOf:member |
| userFilter | String | (&(sAMAccountName=%v)(objectclass=person)) |
| userIdMap | String | user:sAMAccountName |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectclass=dominoGroup)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | dominoGroup:member |
| userFilter | String | (&(uid=%v)(objectclass=Person)) |
| userIdMap | String | person:uid |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)((objectclass=groupOfNames)(objectclass=groupOfUniqueNames))) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | groupOfNames:member;groupOfUniqueNames:uniqueMember |
| userFilter | String | (&(uid=%v)(objectclass=ePerson)) |
| userIdMap | String | *:uid |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectclass=ldapsubentry)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | nsRole:nsRole |
| userFilter | String | (&(uid=%v)(objectclass=inetOrgPerson)) |
| userIdMap | String | inetOrgPerson:uid |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)((objectclass=groupOfNames)(objectclass=groupOfUniqueNames))) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | groupOfNames:member;groupOfUniqueNames:uniqueMember |
| userFilter | String | (&(uid=%v)(objectclass=inetOrgPerson)) |
| userIdMap | String | inetOrgPerson:uid |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectclass=groupOfNames)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | groupOfNames:member |
| userFilter | String | (&(cn=%v)(objectclass=Person)) |
| userIdMap | String | person:cn |
| Attribute name | Data type | Default value |
|---|---|---|
| groupFilter | String | (&(cn=%v)(objectclass=groupOfUniqueNames)) |
| groupIdMap | String | *:cn |
| groupMemberIdMap | String | groupOfUniqueNames:uniquemember |
| userFilter | String | (&(uid=%v)(objectclass=person)) |
| userIdMap | String | *:uid |
Adding egress firewall to prevent DNS loop to unknown hosts
For more information, see Installing network policies for foundational services