Skip to Content.
Sympa Menu

shibboleth-dev - Re: [Shib-Dev] OSGi Bundle - AttributeResolver Cannot Connect to LDAP

Subject: Shibboleth Developers

List archive

Re: [Shib-Dev] OSGi Bundle - AttributeResolver Cannot Connect to LDAP


Chronological Thread 
  • From: Jonathan Tellier <>
  • To: Tom Zeller <>
  • Cc:
  • Subject: Re: [Shib-Dev] OSGi Bundle - AttributeResolver Cannot Connect to LDAP
  • Date: Thu, 16 Dec 2010 15:15:29 -0500
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=skyc0uLJnQ7kJ0OQ44dzsSd07lr4nYpWapf5oemDLI2R3IP130Jw9bVsKHdxF0bLEO ZIWseNkN6JI+Ryg2gsnCLfXTDsk9ac5c2l7zATRLGD19qNAcgfiayRkF5CMaO9rS0fx0 MN/T9985vaB/eSQmvp8r32GRZSJgJgnFGgASc=

Maybe there's a misunderstanding here, but Novell's jldap library does
work fine. It's the use of the javax.naming.ldap classes that does
not.

Actually, I've done some more digging regarding that problem and it
seems that it's related to the Fuse OSGi Container that I'm using.
I've posted my findings there:
http://fusesource.com/forums/thread.jspa?threadID=2448&tstart=0

Jonathan


On Thu, Dec 16, 2010 at 1:44 PM, Tom Zeller
<>
wrote:
>> Note that my basic authn implementation uses Novell's jldap library
>> instead of the javax.naming classes used by the attribute resolver.
>>
>
>> [edu.internet2.middleware.shibboleth.common.attribute.resolver.provider.dataConnector.LdapDataConnector:369]
>> - LDAP data connector myLDAP - An error occured when attempting to
>> search the LDAP: {java.naming.provider.url=ldap://localhost:389,
>> java.naming.factory.initial=com.sun.jndi.ldap.LdapCtxFactory}
>> javax.naming.NotContextException: Not an instance of LdapContext
>>        at
>> javax.naming.ldap.InitialLdapContext.getDefaultLdapInitCtx(InitialLdapContext.java:169)
>
>> I've went through the javax.naming.ldap.InitialLdapContext's code and
>> took a look at javax.naming.spi.NamingManager, which is called by
>> InitialLdapContext, and if my comprehension is right, all the needed
>> classes are found since I don't have any exceptions while loading the
>> factory. It's as if the LdapCtxFactory was not returning the correct
>> object...
>>
>> I don't have a lot of experience in accessing an LDAP directory from
>> within Java, so I might be missing something obvious. Does someone
>> here have an idea of what the problem might be?
>
> Since the shib LdapDataConnector depends on vt-ldap which depends on
> JNDI, I'm not sure you can insert the Novell jldap library without
> providing a new DataConnector (both in code and in your attribute
> resolver configuration) that does not extend the LdapDataConnector.
> I'm thinking that the LdapDataConnector would need to be abstracted to
> support the jldap library.
>
> Tom
>



Archive powered by MHonArc 2.6.16.

Top of Page