cancel
Showing results for 
Search instead for 
Did you mean: 

Error while connecting to LDAP directly

Former Member
0 Kudos

Hi All,

We are working on the server which is connected to LDAP . Here, we are trying to connect directly to ldap with ldap url "ldap://myHost:port" as in below mentioned code :

Hashtable env = new Hashtable();

env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");

env.put(Context.PROVIDER_URL, "ldap://myHost:port");

env.put(Context.SECURITY_AUTHENTICATION, "simple");

env.put(Context.SECURITY_PRINCIPAL, "DC=ad,DC=org,DC=com");

env.put(Context.SECURITY_CREDENTIALS, "");

DirContext ctx = new InitialDirContext(env);

While deploying we got some error as

u201C[LDAP: error code 1 - 00000000: LdapErr: DSID-0C090627, comment: In order to perform this operation a successful bind must be completed on the connection., data 0, vece]u201D.

It seems, we need to pass certain parameters along with url like cn: common name, uid=unique id ,ou=org unit, o=organization. Need some information regarding what all details have to be provided for integration from configtool and in which format like for common name, organization etc.

Also, what should be the entry for Context.SECURITY_PRINCIPAL?

Appreciate an early response.

Thanks in advance.

Regards,

Mitali

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Does your user have access to LDAP to use (Read/Write)? Can you clarify that please.

Thanks

Avik

former_member192434
Active Contributor
0 Kudos

[Start of UME Service Failed |http://help.sap.com/saphelp_nw04/helpdata/en/20/361941edd5ef23e10000000a155106/frameset.htm]check this same exception got resolved..

one more thing, Have you uploaded the LDAP servers certificate in the TrustedCAS of the keystore in Visual Admin in the WAS server? If you are using LDAP ssl the connection to the server will expect a certificate if you dont have the trust enabled you wont be able to connect

Thanks