Reputation: 453
I need to access a website and get information through it. I need to pass through an ldap authentication in ie for this.i just know the ip of the LDAP server.I thought of doing this through JNDI but still I don't know how to get the parameters of the server for authentication. Could someone tell me how to pass on the authentication connecting to this server.
Upvotes: 0
Views: 1324
Reputation: 53486
With a rather vague question I am just going to point you to Spring LDAP which is easy to use and has good documentation on all things related to LDAP and Java.
Upvotes: 1
Reputation: 477
you "need" the information about the server's (host) ip or name and the base DN of the directory where you entries are. you aren't going to find this anywhere - these will be specified by the server that you are trying to connect to.
This is how you generally authenticate against a ldap server:
Upvotes: 0
Reputation: 310840
You can't 'find' it, and you can't 'get' the server parameters for authentication either. You have to know it all in advance. You can make this stuff configuration parameters of your Web-app. In Tomcat you can define an LDAP Resource in context.xml and support it via an LdapObectFactory as described in the Tomcat Resource documentation.
Upvotes: 0