File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes EJB and other Java EE Technologies and the fly likes Attemplting to connect to a public LDAP directory Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Attemplting to connect to a public LDAP directory" Watch "Attemplting to connect to a public LDAP directory" New topic

Attemplting to connect to a public LDAP directory

K Aditi
Ranch Hand

Joined: Mar 17, 2008
Posts: 89
I am trying to retrieve digital certificates from VeriSign public LDAP directory. Sometime back I had posted a question on in the Security forum.Here is the link.
I hope this is the right place to post my continuing question.
Now that I have managed to find the host url(at least I believe I have!), I am attempting to bind to VeriSign's directory using JNDI. Following is the code,

I am getting the following exception:

Exception in thread "main" javax.naming.CommunicationException: [Root exception is No route to host: connect]
at com.sun.jndi.ldap.Connection.<init>(
at com.sun.jndi.ldap.LdapClient.<init>(
at com.sun.jndi.ldap.LdapClient.getInstance(
at com.sun.jndi.ldap.LdapCtx.connect(
at com.sun.jndi.ldap.LdapCtx.<init>(
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(
at javax.naming.spi.NamingManager.getInitialContext(
at javax.naming.InitialContext.getDefaultInitCtx(
at javax.naming.InitialContext.init(
at javax.naming.InitialContext.<init>(
at LDAPConnect.setInitialContext(
at LDAPConnect.main(
Caused by: No route to host: connect
at Method)
at com.sun.jndi.ldap.Connection.createSocket(
at com.sun.jndi.ldap.Connection.<init>(
... 15 more

Is this a firewall issue?being a beginner in LDAP.
Cant figure out what's wrong

I agree. Here's the link:
subject: Attemplting to connect to a public LDAP directory
It's not a secret anymore!