| Author |
LDAP: error code 49 - 80090308: LdapErr: DSID-0C090334
|
Phaneendra Gugggilam
Greenhorn
Joined: Sep 23, 2008
Posts: 14
|
|
|
javax.naming.AuthenticationException: [LDAP: error code 49 - 80090308: LdapErr: DSID-0C090334, comment: AcceptSecurityContext error, data 52e, vece
|
 |
Nitin Pathak
Ranch Hand
Joined: Sep 25, 2006
Posts: 68
|
|
|
This is the typical bad credentials during login error. Can you please elaborate if (read how) you are trying to connect to the Active Directory?
|
 |
Arun Moose
Greenhorn
Joined: Oct 29, 2008
Posts: 9
|
|
HI,
I'm also facing the same error while connecting to LDAP but its intermittent - Root cause: [LDAP: error code 49 - 80090308: LdapErr: DSID-0C090334, comment: AcceptSecurityContext error, data 775, vece#]
The Windows API which i use to talk to Active Directory binds to a domain controller and fecthes the data.
|
 |
manni prat
Greenhorn
Joined: Apr 07, 2011
Posts: 7
|
|
I was getting this error when I was specifying wrong user name and password.
Also ,Please specify domain name while entering the user name.
e.g <domain_name>\<username>
|
 |
rajeesh kunju
Greenhorn
Joined: Aug 08, 2011
Posts: 1
|
|
Hi all,
I am stuck with an AD authentication issue. the scenario is like this
I have two AD services running on two different servers in two domains viz server1.domain1.com and server2.domain2.com
We have a web service on a machine in server1 domain, that can access server1's AD service.
Now , access to server2 AD service is not granted to machines outside the domain. so the web service, cannot access the AD service of server2. we plan to hit server2 AD through server1's AD. How do i replicate this in code in java. I have already coded the first part of accessing server1's AD and can successfully authenticate a user in server1 domain. how do i connect to server2 AD from server1. What configurations do i need to do in code as well as on the server to support this?
String getUsername="abcd";
String searchBase = "dc=domain1,dc=domain2";
Hashtable environment = new Hashtable();
environment.put(LdapContext.CONTROL_FACTORIES, "com.sun.jndi.ldap.ControlFactory ");
System.out.println("one");
environment.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");
System.out.println("two");
environment.put(Context.PROVIDER_URL, "ldap://server1.domain1.com:xxx" );
System.out.println("three");
environment.put(Context.SECURITY_AUTHENTICATION, "simple");
System.out.println("four");
environment.put(Context.SECURITY_PRINCIPAL, "domain1" );
System.out.println("five");
environment.put(Context.SECURITY_CREDENTIALS, "password");
System.out.println("six");
environment.put(Context.STATE_FACTORIES, "PersonStateFactory");
System.out.println("seven");
environment.put(Context.OBJECT_FACTORIES, "PersonObjectFactory");
System.out.println("eight");
try
{
System.out.println("nine");
DirContext ctx = new InitialDirContext(environment);
System.out.println("ten");
String FILTER = "(&(objectClass=Person) ((sAMAccountName=" + getUsername + ")))";
System.out.println("eleven");
SearchControls ctls = new SearchControls();
System.out.println("twelve");
ctls.setSearchScope(SearchControls.SUBTREE_SCOPE);
System.out.println("thirteen");
NamingEnumeration answer = ctx.search(searchBase, FILTER, ctls);
System.out.println("fourteen");
//SearchResult sr = (SearchResult) answer.next();
How do i extend this to access server2's AD from server1 internally
|
 |
 |
|
|
subject: LDAP: error code 49 - 80090308: LdapErr: DSID-0C090334
|
|
|