Re: trying to connect to ADAM instance via JNDI
- From: ravi311@xxxxxxxxx
- Date: 11 Sep 2006 09:05:44 -0700
Hi Joe,
Thanks for your response, I did tried with ldp and I was able
to bind with this username and password in ldp. The problem is when
trying to connect to this through Java code. If I dont give any
password I can connect to it and retrieve all the attributes of that
user.
I did tried to use the display name as username but it
didn't worked. Thanks again for your response.
Ravi
Joe Kaplan wrote:
Can you do a simple bind with this account with ldp.exe (comes with ADAM)?
I'd suggest trying that first. The error code you are getting, 52b, is a
little weird. According to err.exe, that translates to:
# for hex 0x52b / decimal 1323 :
ERROR_WRONG_PASSWORD winerror.h
# Unable to update the password. The value provided as the
# current password is incorrect.
# 1 matches found for "52b"
That looks like an error you would get when trying a change password
operation, not a bind. But maybe the password is just wrong? In any event,
trying a bind with ldp is a good start. Perhaps the account is not enabled
or something.
It may also be worth knowing that you can use the UPN or displayName as a
binding username if you set those. You don't have to use the DN with ADAM.
Joe K.
--
Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--
<ravi311@xxxxxxxxx> wrote in message
news:1157752767.988850.130500@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi ,
I have created an ADAM instance and trying to connect to it
through JNDI, but I am getting this error.
Problem searching directory: javax.naming.AuthenticationException:
[LDAP: error code 49 - 8009030C: LdapErr: DSID-0C090336, comment:
AcceptSecurityContext error, data 52b, va28]
javax.naming.AuthenticationException: [LDAP: error code 49 - 8009030C:
LdapErr: DSID-0C090336, comment: AcceptSecurityContext error, data 52b,
va28]
at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:2988)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2934)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2735)
at com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2649)
at com.sun.jndi.ldap.LdapCtx.<init>(LdapCtx.java:290)
at
com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:175)
at
com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:193)
at
com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:136)
at
com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:66)
at
javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
at
javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
at javax.naming.InitialContext.init(InitialContext.java:219)
at
javax.naming.ldap.InitialLdapContext.<init>(InitialLdapContext.java:133)
at ldap.LDAPTest.main(LDAPTest.java:34)
My code is:
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");
env.put(Context.SECURITY_AUTHENTICATION,"simple");
env.put(Context.SECURITY_PRINCIPAL,"CN=rxg9999,OU=people,OU=clinical,O=Microsoft");
env.put(Context.SECURITY_CREDENTIALS,"q1w2e3");
env.put(Context.PROVIDER_URL, "ldap://localhost:389");
DirContext ctx = new InitialDirContext(env);
This DN CN=rxg9999,OU=people,OU=clinical,O=Microsoft is
added to the member attribute of Administrators also.
Any help is really appreciated.
Thanks
Ravi
.
- References:
- trying to connect to ADAM instance via JNDI
- From: ravi311
- Re: trying to connect to ADAM instance via JNDI
- From: Joe Kaplan
- trying to connect to ADAM instance via JNDI
- Prev by Date: Re: How modify data on ADAM Instance???
- Next by Date: Re: Add Windows 2003 server to Windows 2000 mixed mode server
- Previous by thread: Re: trying to connect to ADAM instance via JNDI
- Next by thread: Re: Schema Update
- Index(es):
Relevant Pages
|