tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1722510 - in /tomcat/trunk: java/org/apache/catalina/authenticator/jaspic/ java/org/apache/catalina/startup/ test/org/apache/catalina/authenticator/ test/org/apache/catalina/authenticator/jaspic/
Date Fri, 01 Jan 2016 17:27:08 GMT
Author: markt
Date: Fri Jan  1 17:27:07 2016
New Revision: 1722510

URL: http://svn.apache.org/viewvc?rev=1722510&view=rev
Log:
Remove JASPIC authenticator and associated modules implemented during GSoC.
See http://tomcat.markmail.org/thread/ar2pdpb6vibu2dwd for reasoning.

Removed:
    tomcat/trunk/java/org/apache/catalina/authenticator/jaspic/
    tomcat/trunk/test/org/apache/catalina/authenticator/TestJaspicBasicAuthenticator.java
    tomcat/trunk/test/org/apache/catalina/authenticator/TestJaspicDigestAuthenticator.java
    tomcat/trunk/test/org/apache/catalina/authenticator/TestJaspicFormAuthenticator.java
    tomcat/trunk/test/org/apache/catalina/authenticator/jaspic/
Modified:
    tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java

Modified: tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java?rev=1722510&r1=1722509&r2=1722510&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java (original)
+++ tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java Fri Jan  1 17:27:07 2016
@@ -39,7 +39,6 @@ import java.util.Properties;
 import java.util.Set;
 import java.util.concurrent.ConcurrentHashMap;
 
-import javax.security.auth.message.config.AuthConfigFactory;
 import javax.servlet.MultipartConfigElement;
 import javax.servlet.ServletContainerInitializer;
 import javax.servlet.ServletContext;
@@ -62,8 +61,6 @@ import org.apache.catalina.Valve;
 import org.apache.catalina.WebResource;
 import org.apache.catalina.WebResourceRoot;
 import org.apache.catalina.Wrapper;
-import org.apache.catalina.authenticator.jaspic.JaspicAuthenticator;
-import org.apache.catalina.authenticator.jaspic.provider.TomcatAuthConfigProvider;
 import org.apache.catalina.core.StandardContext;
 import org.apache.catalina.core.StandardHost;
 import org.apache.catalina.util.ContextName;
@@ -388,15 +385,7 @@ public class ContextConfig implements Li
          */
         Valve authenticator = null;
         if (customAuthenticators != null) {
-            authenticator = (Valve)
-                customAuthenticators.get(loginConfig.getAuthMethod());
-        }
-
-        if (authenticator == null) {
-            String authMethod = loginConfig.getAuthMethod();
-            if (authMethod != null && authMethod.contains("JASPIC")) {
-                authenticator = new JaspicAuthenticator();
-            }
+            authenticator = (Valve) customAuthenticators.get(loginConfig.getAuthMethod());
         }
 
         if (authenticator == null) {
@@ -444,24 +433,6 @@ public class ContextConfig implements Li
 
 
     /**
-     * Configure and register default JASPIC modules
-     */
-    private void configureDefaultJaspicAuthModules() {
-        if (!(context.getAuthenticator() instanceof JaspicAuthenticator)) {
-            return;
-        }
-        // TODO currently we setup default provider if we have
-        // JaspicAuthenicator registred.
-        // we need to find a better way to decide, if we want embedded provider
-        // or not
-        JaspicAuthenticator authenticator = (JaspicAuthenticator) context.getAuthenticator();
-        AuthConfigFactory authConfigFactory = AuthConfigFactory.getFactory();
-        TomcatAuthConfigProvider provider = new TomcatAuthConfigProvider(context, authenticator.getAuthProperties());
-        authConfigFactory.registerConfigProvider(provider, JaspicAuthenticator.MESSAGE_LAYER,
-                authenticator.getAppContext(), "Apache Tomcat JASPIC");
-    }
-
-    /**
      * Create (if necessary) and return a Digester configured to process the
      * context configuration descriptor for an application.
      */
@@ -806,7 +777,6 @@ public class ContextConfig implements Li
         // Configure an authenticator if we need one
         if (ok) {
             authenticatorConfig();
-            configureDefaultJaspicAuthModules();
         }
 
         // Dump the contents of this pipeline if requested



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


Mime
View raw message