Return-Path: Delivered-To: apmail-jakarta-tomcat-dev-archive@apache.org Received: (qmail 18480 invoked from network); 19 Nov 2002 01:26:49 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 19 Nov 2002 01:26:49 -0000 Received: (qmail 9038 invoked by uid 97); 19 Nov 2002 01:27:50 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-dev@jakarta.apache.org Received: (qmail 9021 invoked by uid 97); 19 Nov 2002 01:27:50 -0000 Mailing-List: contact tomcat-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Developers List" Reply-To: "Tomcat Developers List" Delivered-To: mailing list tomcat-dev@jakarta.apache.org Received: (qmail 9010 invoked by uid 97); 19 Nov 2002 01:27:49 -0000 X-Antivirus: nagoya (v4218 created Aug 14 2002) Date: 19 Nov 2002 01:26:38 -0000 Message-ID: <20021119012638.25316.qmail@icarus.apache.org> From: amyroh@apache.org To: jakarta-tomcat-4.0-cvs@apache.org Subject: cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/realm JNDIRealm.java X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N amyroh 2002/11/18 17:26:38 Modified: catalina/src/share/org/apache/catalina/realm JNDIRealm.java Log: Add to configure how JNDI should handle referrals returned by the server. Submitted by Christopher Taylor . Revision Changes Path 1.10 +34 -5 jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/realm/JNDIRealm.java Index: JNDIRealm.java =================================================================== RCS file: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/realm/JNDIRealm.java,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- JNDIRealm.java 12 Nov 2002 01:13:37 -0000 1.9 +++ JNDIRealm.java 19 Nov 2002 01:26:38 -0000 1.10 @@ -237,11 +237,21 @@ */ protected static final String name = "JNDIRealm"; + /** * The protocol that will be used in the communication with the directory server. */ protected String protocol = null; + + /** + * How should we handle referrals? Microsoft Active Directory can't handle + * the default case, so an application authenticating against AD must + * set referrals to "follow". + */ + protected String referrals = null; + + /** * The base element for user searches. */ @@ -460,6 +470,23 @@ /** + * Returns the current settings for handling JNDI referrals. + */ + public String getReferrals () { + return referrals; + } + + + /** + * How do we handle JNDI referrals? ignore, follow, or throw + * (see javax.naming.Context.REFERRAL for more information). + */ + public void setReferrals (String referrals) { + this.referrals = referrals; + } + + + /** * Return the base element for user searches. */ public String getUserBase() { @@ -1345,7 +1372,9 @@ if (authentication != null) env.put(Context.SECURITY_AUTHENTICATION, authentication); if (protocol != null) - env.put(Context.SECURITY_PROTOCOL, protocol); + env.put(Context.SECURITY_PROTOCOL, protocol); + if (referrals != null) + env.put(Context.REFERRAL, referrals); context = new InitialDirContext(env); return (context); -- To unsubscribe, e-mail: For additional commands, e-mail: