You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by ja...@apache.org on 2007/07/19 14:06:13 UTC

svn commit: r557590 - /lenya/trunk/src/modules-core/ldap/java/src/org/apache/lenya/ac/ldap/LDAPUser.java

Author: jann
Date: Thu Jul 19 05:06:12 2007
New Revision: 557590

URL: http://svn.apache.org/viewvc?view=rev&rev=557590
Log:
Adding support for Referrals. Otherwise a ldap server which uses referrals will not find a user (or another object)

Modified:
    lenya/trunk/src/modules-core/ldap/java/src/org/apache/lenya/ac/ldap/LDAPUser.java

Modified: lenya/trunk/src/modules-core/ldap/java/src/org/apache/lenya/ac/ldap/LDAPUser.java
URL: http://svn.apache.org/viewvc/lenya/trunk/src/modules-core/ldap/java/src/org/apache/lenya/ac/ldap/LDAPUser.java?view=diff&rev=557590&r1=557589&r2=557590
==============================================================================
--- lenya/trunk/src/modules-core/ldap/java/src/org/apache/lenya/ac/ldap/LDAPUser.java (original)
+++ lenya/trunk/src/modules-core/ldap/java/src/org/apache/lenya/ac/ldap/LDAPUser.java Thu Jul 19 05:06:12 2007
@@ -78,6 +78,8 @@
     private static String USR_AUTH_TYPE_DEFAULT = "simple";
     private static String BASE_DN_PROP = "base-dn";
     private static String DOMAIN_NAME_PROP = "domain-name";
+    private static String HANDLE_REFERRALS_PROP = "handle-referrals";
+    private static String HANDLE_REFERRALS_DEFAULT = "ignore";
 
     private String ldapId;
     private String ldapName;
@@ -350,6 +352,7 @@
             env.put(Context.SECURITY_PRINCIPAL, principal);
             env.put(Context.SECURITY_CREDENTIALS, credentials);
         }
+        env.put(Context.REFERRAL, defaultProperties.getProperty(HANDLE_REFERRALS_PROP, HANDLE_REFERRALS_DEFAULT));
 
         DirContext ctx = new InitialLdapContext(env, null);
 



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@lenya.apache.org
For additional commands, e-mail: commits-help@lenya.apache.org