Dynamically updating the bind DN and password for an LDAP repository

Use this procedure to dynamically update the LDAP bind information of the specified LDAP repository at runtime.

About this task

Note: When this dynamic call is made, only the configuration in memory is updated. The configuration file is not updated.
Event Type
DYNA_CONFIG_EVENT_UPDATE_LDAP_BIND_INFO
Configuration Data
DYNA_CONFIG_KEY_LDAP_BIND_DN - [String]
Specifies the new LDAP bind distinguished name (DN).
DYNA_CONFIG_KEY_LDAP_BIND_PASSWORD - [UTF-8 encoded byte array]
Specifies the new LDAP bind password.
DYNA_CONFIG_KEY_REPOS_ID (required) - [String]
Specifies the repository ID of the LDAP adapter you want to update.
The following is a sample task:

Procedure

  1. Ensure that virtual member manager is running.
  2. Call dynamicUpdateConfig API to update the bind DN and password. For example to update the bind password:
    Hashtable configData = new Hashtable();
    configData.put(Service.DYNA_CONFIG_KEY_LDAP_BIND_DN, "uid=testwim,cn=users,dc=yourco,dc=com");
    configData.put(Service.DYNA_CONFIG_KEY_LDAP_BIND_PASSWORD, PasswordUtil.getByteArrayPassword
                  ("rightpwd"));
    configData.put(Service.DYNA_CONFIG_KEY_REPOS_ID, "LDAP1");		
    service.dynamicUpdateConfig(Service.DYNA_CONFIG_EVENT_UPDATE_LDAP_BIND_INFO, configData);
Terms of use | Feedback
(C) Copyright IBM Corporation 2005. All Rights Reserved.
IBM virtual member manager 6.1