Jahia Install Forum > Jahia with multiple...

0 (0 Good)
0 (0 Bad)

Jahia with multiple LDAP

by  umeunier »  2011/06/07 20:56

Hi,

I have successfully configured Jahia to use OpenLDAP, I can see my users in the Administration site. But my users are stored in two distinct LDAP : OpenLDAP and AD.
How can I configure Jahia to have access to all my users?

Thanks,
Laurent
  • Jahia with multiple LDAP
    2011/06/07 20:56

    umeunier Hi,<br/><br/>I have successfully configured Jahia to use OpenLDAP, I can see my users in the Administration site. But my users are stored in two distinct LDAP : OpenLDAP and AD.<br/>How can I configure Jahia to have access to all my users?<br/><br/>Thanks,<br/>Laurent

  • Number of messages  5
    Registration date Jun 7, 2011
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  pap@commaro.com »  2011/06/07 20:56

    Hello,

    in Jahia 6.1 you can configure different providers in etc\spring\applicationcontext-services.xml. There is already an example "JahiaUserManagerLDAPProvider" bean in there. You just need to uncomment it and adapt the configurations e.g. to your OpenLDAP server. If you want to have a second provider, just copy the whole definition of the "JahiaUserManagerLDAPProvider" and create e.g. "JahiaUserManagerLDAPProvider2".

    You need to change the values of the following properties in the second provider:

    <property name="key" value="ldap2"/>
    ...
    <property name="priority" value="3"/>

    and of course the settings in the ldapProperties section to point to your AD server.

    What you also need to do is to delete factory-method="getInstance" from both LDAP provider bean definitions as otherwise both will point to the same singleton.

    Then in the definition of bean "org.jahia.services.usermanager.JahiaUserManagerRoutingService" you just need to activate/add both LDAP providers: 

    <property name="providersTable">
    <map>
    <entry key="jahia_db" value-ref="JahiaUserManagerDBProvider" />
    <entry key="ldap" value-ref="JahiaUserManagerLDAPProvider"/>
    <entry key="ldap2" value-ref="JahiaUserManagerLDAPProvider2"/>
    </map>
    </property>


    With group providers you could do the same if you need to access groups on both LDAP servers. 

    In Jahia 6.5 the logic is the same, just that the configurations were moved to different files. The providers are configured in etc\spring\users-groups\applicationcontext-users-ldap.xml (you need to remove the suffix .disabled from the filename). And you do not need to configure the "providersTable" any longer as the providers will register themselves to the routing service.

    Let me know if you have further questions or if you still get problems.

    Regards,
    Benjamin

    Benjamin Papez (pap@commaro.com)

    Number of messages  220
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  umeunier »  2011/06/07 20:56

     

    Hi Benjamin,

     

    Thanks for your help and the tip about removing factory-method="getInstance" from both LDAP provider bean definitions. Now I can see all my users and search them throught the administration interface.

    I still get a error when trying to authenticate in the ACME site.

    - with users from ldap1:

    I just have an error message around the authentication box saying "Invalid username/password". The password is correct, I have checked it 2 times.

    - with users from ldap2: 

    In firefox: "An unexpected error occurred during processing of the request. Please retry the operation later."

    In the catalina.out file :

    2010-09-02 10:26:50,641: ERROR [ErrorLoggingFilter] - java.lang.NullPointerException
    
    java.lang.NullPointerException
    
       at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.lookupUserByKey(JahiaUserManagerLDAPProvider.java:1046)
    
       at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.login(JahiaUserManagerLDAPProvider.java:580)
    
       at org.jahia.services.usermanager.JahiaLDAPUser.verifyPassword(JahiaLDAPUser.java:389)
    
       at org.jahia.params.valves.LoginEngineAuthValveImpl.invoke(LoginEngineAuthValveImpl.java:93)
    
       at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163)
    
       at org.jahia.params.valves.TokenAuthValveImpl.invoke(TokenAuthValveImpl.java:61)
    
       at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163)
    
       at org.jahia.params.valves.HttpBasicAuthValveImpl.invoke(HttpBasicAuthValveImpl.java:80)
    
       at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163)
    
       at org.jahia.pipelines.impl.GenericPipeline.invoke(GenericPipeline.java:150)
    
       at org.jahia.params.ProcessingContext.resolveUser(ProcessingContext.java:3567)
    
       at org.jahia.params.ParamBean.<init>(ParamBean.java:390)
    
       at org.jahia.params.ParamBean.<init>(ParamBean.java:294)
    
       at org.jahia.params.ProcessingContextFactoryImpl.getContext(ProcessingContextFactoryImpl.java:51)
    
       at org.jahia.bin.Jahia.createParamBean(Jahia.java:885)
    
       at org.jahia.bin.Jahia.service(Jahia.java:824)
    
       at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)
    
       at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436)
    
       at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)
    
       at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)
    
       at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195)
    
       at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159)
    
       at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
    
       at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
    
       at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.jahia.bin.filters.jcr.JcrSessionFilter.doFilter(JcrSessionFilter.java:40)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.jahia.bin.filters.ResponseCacheControlFilter.doFilter(ResponseCacheControlFilter.java:93)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
    
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    
       at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
    
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
    
       at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
    
       at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568)
    
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    
       at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
    
       at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190)
    
       at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283)
    
       at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767)
    
       at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697)
    
       at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889)
    
       at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690)
    
       at java.lang.Thread.run(Thread.java:619)

    Regards,

    Laurent

  • Re: Jahia with multiple LDAP
    2011/07/04 15:02

    umeunier <p> &nbsp;</p> <p> <title></title> </p> <p> Hi Benjamin,</p> <p> &nbsp;</p> <p> Thanks for your help and the tip about removing factory-method=&quot;getInstance&quot; from both LDAP provider bean definitions. Now I can see all my users and search them throught the administration interface.</p> <p> I still get a error when trying to authenticate in the ACME site.</p> <p> - with users from ldap1:</p> <p> I just have an error message around the authentication box saying &quot;Invalid username/password&quot;. The password is correct, I have checked it 2 times.</p> <p> - with users from ldap2:&nbsp;</p> <p> In firefox: &quot;An unexpected error occurred during processing of the request. Please retry the operation later.&quot;</p> <p> In the catalina.out file :</p> <pre> 2010-09-02 10:26:50,641: ERROR [ErrorLoggingFilter] - java.lang.NullPointerException java.lang.NullPointerException at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.lookupUserByKey(JahiaUserManagerLDAPProvider.java:1046) at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.login(JahiaUserManagerLDAPProvider.java:580) at org.jahia.services.usermanager.JahiaLDAPUser.verifyPassword(JahiaLDAPUser.java:389) at org.jahia.params.valves.LoginEngineAuthValveImpl.invoke(LoginEngineAuthValveImpl.java:93) at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163) at org.jahia.params.valves.TokenAuthValveImpl.invoke(TokenAuthValveImpl.java:61) at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163) at org.jahia.params.valves.HttpBasicAuthValveImpl.invoke(HttpBasicAuthValveImpl.java:80) at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163) at org.jahia.pipelines.impl.GenericPipeline.invoke(GenericPipeline.java:150) at org.jahia.params.ProcessingContext.resolveUser(ProcessingContext.java:3567) at org.jahia.params.ParamBean.&lt;init&gt;(ParamBean.java:390) at org.jahia.params.ParamBean.&lt;init&gt;(ParamBean.java:294) at org.jahia.params.ProcessingContextFactoryImpl.getContext(ProcessingContextFactoryImpl.java:51) at org.jahia.bin.Jahia.createParamBean(Jahia.java:885) at org.jahia.bin.Jahia.service(Jahia.java:824) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302) at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195) at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159) at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141) at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90) at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.jahia.bin.filters.jcr.JcrSessionFilter.doFilter(JcrSessionFilter.java:40) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.jahia.bin.filters.ResponseCacheControlFilter.doFilter(ResponseCacheControlFilter.java:93) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619)</pre> <p> Regards,</p> <p> Laurent</p>

  • Number of messages  5
    Registration date Jun 7, 2011
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  pap@commaro.com »  2011/06/07 20:56

    Hello Laurent,

    can you please tell us which Jahia release you are using, so that I can match up the stacktrace with the code ?

    Thanks,
    Benjamin

    Benjamin Papez (pap@commaro.com)

    Number of messages  220
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  umeunier »  2011/06/07 20:56

    Sorry, I have forgotten to tell you which version I've installed...

    I'm using Jahia EE v6.1 r31127 (tomcat/linux) patched to r32952.

    Regards,
    Laurent
  • Re: Jahia with multiple LDAP
    2011/06/07 20:56

    umeunier Sorry, I have forgotten to tell you which version I've installed...<br/><br/>I'm using Jahia EE v6.1 r31127 (tomcat/linux) patched to r32952.<br/><br/>Regards,<br/>Laurent

  • Number of messages  5
    Registration date Jun 7, 2011
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  pap@commaro.com »  2011/06/07 20:56

    Hi Laurent,

    do you get any exceptions logged while starting Jahia ? I have looked at the line 1046 and the NullPointerException can only come if the mProvidersUserCache variable is not initialized. This is done in the start method of the JahiaUserManagerLDAPProvider. If you do not see any exceptions, please add the following to etc\config\log4j.xml:

    <category name="org.jahia.services.usermanager.JahiaUserManagerLDAPProvider">
    <priority value="debug"/>
    </category>

    Then restart the server. On startup you should see two lines printed saying:
    "Initialized and connected to public repository"

    If this is not the case, you can try adding init-method="start" to both of your JahiaUserManagerLDAPProvider bean definitions in etc\spring\applicationcontext-services.xml .

    Regards,
    Benjamin

    Benjamin Papez (pap@commaro.com)

    Number of messages  220
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  umeunier »  2011/06/07 20:57

    Hi Benjamin,

    Debug output during startup:

     

    2010-09-02 12:02:00,002: DEBUG [JahiaUserManagerLDAPProvider] - Initialized and connected to public repository
    
    2010-09-02 12:02:00,004: DEBUG [JahiaUserManagerLDAPProvider] - Initialized and connected to public repository
    
    ...
    
    2010-09-02 12:02:06,902: DEBUG [JahiaUserManagerLDAPProvider] - Attempting connection to LDAP repository on ldap://127.0.0.1:389/...
    
    2010-09-02 12:02:06,903: DEBUG [JahiaUserManagerLDAPProvider] - Using authentification mode to connect to public dir...
    
    2010-09-02 12:02:06,928: DEBUG [JahiaUserManagerLDAPProvider] - Using filter string [(&(objectClass=inetOrgPerson)(uid= system ))]...
    
    2010-09-02 12:02:06,932: DEBUG [JahiaUserManagerLDAPProvider] - Attempting connection to LDAP repository on ldap://ldap.example.com:389/...
    
    2010-09-02 12:02:06,932: DEBUG [JahiaUserManagerLDAPProvider] - Using authentification mode to connect to public dir...
    
    2010-09-02 12:02:06,946: DEBUG [JahiaUserManagerLDAPProvider] - Using filter string [(&(objectClass=inetOrgPerson)(uid= system ))]...

    And when I try to authenticate:

    2010-09-02 12:02:37,836: DEBUG [JahiaUserManagerLDAPProvider] - Attempting connection to LDAP repository on ldap://127.0.0.1:389/...
    
    2010-09-02 12:02:37,836: DEBUG [JahiaUserManagerLDAPProvider] - Using authentification mode to connect to public dir...
    
    2010-09-02 12:02:37,837: DEBUG [JahiaUserManagerLDAPProvider] - Using filter string [(&(objectClass=inetOrgPerson)(uid=elu1))]...
    
    2010-09-02 12:02:37,845: DEBUG [JahiaUserManagerLDAPProvider] - Context passed is null, ignoring it...
    
    2010-09-02 12:02:37,875: ERROR [ErrorLoggingFilter] - java.lang.NullPointerException
    
    java.lang.NullPointerException
    
       at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.lookupUserByKey(JahiaUserManagerLDAPProvider.java:1046)
    
       at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.login(JahiaUserManagerLDAPProvider.java:580)
    
       at org.jahia.services.usermanager.JahiaLDAPUser.verifyPassword(JahiaLDAPUser.java:389)
    
       at org.jahia.params.valves.LoginEngineAuthValveImpl.invoke(LoginEngineAuthValveImpl.java:93)
    
       at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163)
    
       at org.jahia.params.valves.TokenAuthValveImpl.invoke(TokenAuthValveImpl.java:61)
    
       at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163)
    
       at org.jahia.params.valves.HttpBasicAuthValveImpl.invoke(HttpBasicAuthValveImpl.java:80)
    
       at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163)
    
       at org.jahia.pipelines.impl.GenericPipeline.invoke(GenericPipeline.java:150)
    
       at org.jahia.params.ProcessingContext.resolveUser(ProcessingContext.java:3567)
    
       at org.jahia.params.ParamBean.<init>(ParamBean.java:390)
    
       at org.jahia.params.ParamBean.<init>(ParamBean.java:294)
    
       at org.jahia.params.ProcessingContextFactoryImpl.getContext(ProcessingContextFactoryImpl.java:51)
    
       at org.jahia.bin.Jahia.createParamBean(Jahia.java:885)
    
       at org.jahia.bin.Jahia.service(Jahia.java:824)
    
       at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)
    
       at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436)
    
       at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)
    
       at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)
    
       at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195)
    
       at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159)
    
       at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
    
       at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
    
       at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.jahia.bin.filters.jcr.JcrSessionFilter.doFilter(JcrSessionFilter.java:40)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.jahia.bin.filters.ResponseCacheControlFilter.doFilter(ResponseCacheControlFilter.java:93)
    
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
    
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    
       at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
    
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
    
       at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
    
       at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568)
    
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    
       at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
    
       at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190)
    
       at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283)
    
       at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767)
    
       at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697)
    
       at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889)
    
       at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690)
    
       at java.lang.Thread.run(Thread.java:619)
    
    2010-09-02 12:02:37,889: DEBUG [JahiaUserManagerLDAPProvider] - Context passed is null, ignoring it...

    And finally, adding init-method="start" don't change anything.

     

    Laurent

  • Re: Jahia with multiple LDAP
    2011/07/04 15:05

    umeunier <p> Hi Benjamin,<br /> <br /> Debug output during startup:</p> <p> &nbsp;</p> <p> <title></title> </p> <pre> 2010-09-02 12:02:00,002: DEBUG [JahiaUserManagerLDAPProvider] - Initialized and connected to public repository 2010-09-02 12:02:00,004: DEBUG [JahiaUserManagerLDAPProvider] - Initialized and connected to public repository ... 2010-09-02 12:02:06,902: DEBUG [JahiaUserManagerLDAPProvider] - Attempting connection to LDAP repository on ldap://127.0.0.1:389/... 2010-09-02 12:02:06,903: DEBUG [JahiaUserManagerLDAPProvider] - Using authentification mode to connect to public dir... 2010-09-02 12:02:06,928: DEBUG [JahiaUserManagerLDAPProvider] - Using filter string [(&amp;(objectClass=inetOrgPerson)(uid= system ))]... 2010-09-02 12:02:06,932: DEBUG [JahiaUserManagerLDAPProvider] - Attempting connection to LDAP repository on ldap://ldap.example.com:389/... 2010-09-02 12:02:06,932: DEBUG [JahiaUserManagerLDAPProvider] - Using authentification mode to connect to public dir... 2010-09-02 12:02:06,946: DEBUG [JahiaUserManagerLDAPProvider] - Using filter string [(&amp;(objectClass=inetOrgPerson)(uid= system ))]...</pre> <p> And when I try to authenticate:</p> <pre> 2010-09-02 12:02:37,836: DEBUG [JahiaUserManagerLDAPProvider] - Attempting connection to LDAP repository on ldap://127.0.0.1:389/... 2010-09-02 12:02:37,836: DEBUG [JahiaUserManagerLDAPProvider] - Using authentification mode to connect to public dir... 2010-09-02 12:02:37,837: DEBUG [JahiaUserManagerLDAPProvider] - Using filter string [(&amp;(objectClass=inetOrgPerson)(uid=elu1))]... 2010-09-02 12:02:37,845: DEBUG [JahiaUserManagerLDAPProvider] - Context passed is null, ignoring it... 2010-09-02 12:02:37,875: ERROR [ErrorLoggingFilter] - java.lang.NullPointerException java.lang.NullPointerException at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.lookupUserByKey(JahiaUserManagerLDAPProvider.java:1046) at org.jahia.services.usermanager.JahiaUserManagerLDAPProvider.login(JahiaUserManagerLDAPProvider.java:580) at org.jahia.services.usermanager.JahiaLDAPUser.verifyPassword(JahiaLDAPUser.java:389) at org.jahia.params.valves.LoginEngineAuthValveImpl.invoke(LoginEngineAuthValveImpl.java:93) at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163) at org.jahia.params.valves.TokenAuthValveImpl.invoke(TokenAuthValveImpl.java:61) at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163) at org.jahia.params.valves.HttpBasicAuthValveImpl.invoke(HttpBasicAuthValveImpl.java:80) at org.jahia.pipelines.impl.GenericPipeline.invokeNext(GenericPipeline.java:163) at org.jahia.pipelines.impl.GenericPipeline.invoke(GenericPipeline.java:150) at org.jahia.params.ProcessingContext.resolveUser(ProcessingContext.java:3567) at org.jahia.params.ParamBean.&lt;init&gt;(ParamBean.java:390) at org.jahia.params.ParamBean.&lt;init&gt;(ParamBean.java:294) at org.jahia.params.ProcessingContextFactoryImpl.getContext(ProcessingContextFactoryImpl.java:51) at org.jahia.bin.Jahia.createParamBean(Jahia.java:885) at org.jahia.bin.Jahia.service(Jahia.java:824) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302) at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195) at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159) at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141) at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90) at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.jahia.bin.filters.jcr.JcrSessionFilter.doFilter(JcrSessionFilter.java:40) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.jahia.bin.filters.ResponseCacheControlFilter.doFilter(ResponseCacheControlFilter.java:93) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) 2010-09-02 12:02:37,889: DEBUG [JahiaUserManagerLDAPProvider] - Context passed is null, ignoring it...</pre> <p> And finally, adding init-method=&quot;start&quot; don&#39;t change anything.</p> <p> &nbsp;</p> <p> Laurent</p>

  • Number of messages  5
    Registration date Jun 7, 2011
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  pap@commaro.com »  2011/06/07 20:57

    Hello,

    actually I found a bug in the JahiaLDAPUser.verifyPassword method, which uses JahiaUserManagerLDAPProvider.getInstance() instead of the provider, which is stored in the object itself. We have opened a JIRA issue and will include the fix in one of the next hotfixes.

    Regards,
    Benjamin

    Benjamin Papez (pap@commaro.com)

    Number of messages  220
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  umeunier »  2011/06/07 20:57

    Benjamin,

    Can you give me a link the JIRA issue you have opened? I can't find it on http://jira.jahia.org and my account on http://support.jahia.com seems to be somewhat limited...

    Do you know when the hotfix will be available? (a few days or a few months?)

    Anyways, many thanks for your help.

    Thanks,
    Laurent
  • Re: Jahia with multiple LDAP
    2011/06/07 20:57

    umeunier Benjamin,<br/><br/>Can you give me a link the JIRA issue you have opened? I can't find it on <!-- m --><a class="postlink" href="http://jira.jahia.org">http://jira.jahia.org</a><!-- m --> and my account on <!-- m --><a class="postlink" href="http://support.jahia.com">http://support.jahia.com</a><!-- m --> seems to be somewhat limited...<br/><br/>Do you know when the hotfix will be available? (a few days or a few months?)<br/><br/>Anyways, many thanks for your help.<br/><br/>Thanks,<br/>Laurent

  • Number of messages  5
    Registration date Jun 7, 2011
    0 (0 Good)
    0 (0 Bad)

    Re: Jahia with multiple LDAP

    by  trenaud »  2011/06/07 20:57

    Hi,

    By the way and on a side note - but quite important - the Jahia QA team does not test Jahia with several providers. That's not something Jahia EE generically supports. But we can - thanks to this forum - improve the product and try to fix some bugs however laugh Just to mention the fact that right now, the product (6.1) is not generically designed nor tested for using different providers. That said, in the roadmap post 6.5, that's something in discussion as the requirement is not so rare.

    We are going to release soon our roadmap post 6.5 and people/community will be able to comment it freely. Depending on the feedbacks, supporting several providers could become generically supported.

    Tristan

  • Re: Jahia with multiple LDAP
    2011/07/04 15:06

    trenaud <p> Hi,<br /> <br /> By the way and on a side note - but quite important - the Jahia QA team does not test Jahia with several providers. That&#39;s not something Jahia EE generically supports. But we can - thanks to this forum - improve the product and try to fix some bugs however <img alt="laugh" height="20" src="https://www.jahia.com/modules/assets/javascript/ckeditor/plugins/smiley/images/teeth_smile.gif" title="laugh" width="20" />&nbsp;Just to mention the fact that right now, the product (6.1) is not generically designed nor tested for using different providers. That said, in the roadmap post 6.5, that&#39;s something in discussion as the requirement is not so rare.<br /> <br /> We are going to release soon our roadmap post 6.5 and people/community will be able to comment it freely. Depending on the feedbacks, supporting several providers could become generically supported.<br /> <br /> Tristan</p>

  • Number of messages  71
    Registration date Jun 7, 2011
    Contact
    Share
    Feedback

    Get in touch

    Whether you are a current user or if you are just evaluating Jahia, we are here to help.

    Contact us

    Share this page