tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1230957 - /tomcat/trunk/java/org/apache/catalina/core/StandardEngine.java
Date Fri, 13 Jan 2012 09:25:04 GMT
Author: markt
Date: Fri Jan 13 09:25:04 2012
New Revision: 1230957

URL: http://svn.apache.org/viewvc?rev=1230957&view=rev
Log:
Switch to use the new NullRealm by default

Modified:
    tomcat/trunk/java/org/apache/catalina/core/StandardEngine.java

Modified: tomcat/trunk/java/org/apache/catalina/core/StandardEngine.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/StandardEngine.java?rev=1230957&r1=1230956&r2=1230957&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/core/StandardEngine.java (original)
+++ tomcat/trunk/java/org/apache/catalina/core/StandardEngine.java Fri Jan 13 09:25:04 2012
@@ -37,7 +37,7 @@ import org.apache.catalina.Realm;
 import org.apache.catalina.Service;
 import org.apache.catalina.connector.Request;
 import org.apache.catalina.connector.Response;
-import org.apache.catalina.realm.JAASRealm;
+import org.apache.catalina.realm.NullRealm;
 import org.apache.catalina.util.ServerInfo;
 import org.apache.juli.logging.Log;
 import org.apache.juli.logging.LogFactory;
@@ -114,18 +114,20 @@ public class StandardEngine extends Cont
 
     // ------------------------------------------------------------- Properties
 
-    /** Provide a default in case no explicit configuration is set
+    /**
+     * Obtain the configured Realm and provide a default Realm implementation
+     * when no explicit configuration is set.
      *
-     * @return configured realm, or a JAAS realm by default
+     * @return configured realm, or a {@link NullRealm} by default
      */
     @Override
     public Realm getRealm() {
-        Realm configured=super.getRealm();
-        // If no set realm has been called - default to JAAS
+        Realm configured = super.getRealm();
+        // If no set realm has been called - default to NullRealm
         // This can be overridden at engine, context and host level
-        if( configured==null ) {
-            configured=new JAASRealm();
-            this.setRealm( configured );
+        if (configured == null) {
+            configured = new NullRealm();
+            this.setRealm(configured);
         }
         return configured;
     }



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message