directory-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kiran Ayyagari <ayyagariki...@gmail.com>
Subject Re: ssl connections to apacheds
Date Thu, 25 Feb 2010 21:58:34 GMT
hi Laszlo,
> Also another question. I read that apacheds supports TLS but when I try connect
> with the client I got the following exception:
>
> javax.naming.CommunicationException: [LDAP: error code 2 - Unrecognized extended
> operation EXTENSION_OID: 1.3.6.1.4.1.1466.20037]; remaining name ''

 did you register the StartTls extension operation andler before
starting the server

>
> My client looks like:
>
> private InitialDirContext connectTotServer() throws NamingException,
>                                       IOException{
>        final String url = "ldaps://localhost:10389";
>
>        InitialLdapContext context = new InitialLdapContext(new Hashtable() {{
>            put(INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");
>            put(PROVIDER_URL, url);
>        }}, null);
>        StartTlsResponse tlsResponse = (StartTlsResponse)context.
>                                 extendedOperation(new StartTlsRequest());
>        tlsResponse.negotiate();
>        return context;
> }
>

take a look at the test case [1] which I think might help you in
getting this right

[1] http://svn.apache.org/repos/asf/directory/apacheds/trunk/server-integ/src/test/java/org/apache/directory/server/ssl/StartTlsIT.java

Kiran Ayyagari

Mime
View raw message