geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xuhaih...@apache.org
Subject svn commit: r1026274 - in /geronimo/server/trunk/plugins/tomcat: geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/ geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/listener/ geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/se...
Date Fri, 22 Oct 2010 10:11:59 GMT
Author: xuhaihong
Date: Fri Oct 22 10:11:58 2010
New Revision: 1026274

URL: http://svn.apache.org/viewvc?rev=1026274&view=rev
Log:
Update codes due to recent changes in Tomcat trunk

Removed:
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/listener/GeronimoAprLifecycleListener.java
Modified:
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/TomcatContainer.java
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/SecurityValve.java
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/ClientCertAuthenticator.java
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/FormAuthenticator.java
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/jacc/JACCRealm.java
    geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/test/java/org/apache/geronimo/tomcat/AbstractWebModuleTest.java
    geronimo/server/trunk/plugins/tomcat/tomcat7/src/main/history/dependencies.xml

Modified: geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/TomcatContainer.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/TomcatContainer.java?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/TomcatContainer.java
(original)
+++ geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/TomcatContainer.java
Fri Oct 22 10:11:58 2010
@@ -19,7 +19,6 @@ package org.apache.geronimo.tomcat;
 import java.io.File;
 import java.net.URL;
 import java.net.URLStreamHandlerFactory;
-import java.util.Collection;
 import java.util.HashMap;
 import java.util.Map;
 import java.util.Properties;
@@ -52,6 +51,7 @@ import org.apache.geronimo.osgi.web.WebA
 import org.apache.geronimo.security.ContextManager;
 import org.apache.geronimo.security.jaas.ConfigurationFactory;
 import org.apache.geronimo.system.serverinfo.ServerInfo;
+import org.apache.geronimo.web.WebAttributeName;
 import org.apache.geronimo.web.info.WebAppInfo;
 import org.apache.geronimo.webservices.SoapHandler;
 import org.apache.geronimo.webservices.WebServiceContainer;
@@ -298,6 +298,7 @@ public class TomcatContainer implements 
         // set the bundle context attribute in the servlet context
         context.getServletContext().setAttribute(WebApplicationConstants.BUNDLE_CONTEXT_ATTRIBUTE,
                                                  contextInfo.getBundle().getBundleContext());
+        context.getServletContext().setAttribute(WebAttributeName.WEB_APP_INFO.name(), contextInfo.getWebAppInfo());
 
         // now set the module context ValidatorFactory in a context property.
         try {
@@ -404,7 +405,6 @@ public class TomcatContainer implements 
         } catch (Exception e) {
             throw new RuntimeException(e);
         }
-        context.getParent().removeChild(context);
         webServices.remove(contextPath);
     }
 

Modified: geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/SecurityValve.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/SecurityValve.java?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/SecurityValve.java
(original)
+++ geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/SecurityValve.java
Fri Oct 22 10:11:58 2010
@@ -141,13 +141,7 @@ public class SecurityValve extends Valve
         } catch (ServerAuthException e) {
             throw new IOException(e.getMessage(), e.getCause());
         }
-    }
-
-    @Override
-    public void register(Request request, HttpServletResponse response, Principal principal,
String authType, String username, String password) {
-        //we don't do this, session tracking is done by the jaspic authenticators
-        throw new IllegalStateException("should not be called in geronimo integration");
-    }
+    }    
 
     @Override
     public void login(String username, String password, Request request) throws ServletException
{

Modified: geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/ClientCertAuthenticator.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/ClientCertAuthenticator.java?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/ClientCertAuthenticator.java
(original)
+++ geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/ClientCertAuthenticator.java
Fri Oct 22 10:11:58 2010
@@ -61,7 +61,7 @@ public class ClientCertAuthenticator imp
             request.getAttribute(Globals.CERTIFICATES_ATTR);
         if ((certs == null) || (certs.length < 1)) {
             request.getCoyoteRequest().action
-                              (ActionCode.ACTION_REQ_SSL_CERTIFICATE, null);
+                              (ActionCode.REQ_SSL_CERTIFICATE, null);
             certs = (X509Certificate[])
                 request.getAttribute(Globals.CERTIFICATES_ATTR);
         }

Modified: geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/FormAuthenticator.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/FormAuthenticator.java?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/FormAuthenticator.java
(original)
+++ geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/authentication/FormAuthenticator.java
Fri Oct 22 10:11:58 2010
@@ -323,7 +323,7 @@ public class FormAuthenticator implement
 
             if (body != null) {
                 request.getCoyoteRequest().action
-                        (ActionCode.ACTION_REQ_SET_BODY_REPLAY, body);
+                        (ActionCode.REQ_SET_BODY_REPLAY, body);
 
                 // Set content type
                 MessageBytes contentType = MessageBytes.newInstance();

Modified: geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/jacc/JACCRealm.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/jacc/JACCRealm.java?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/jacc/JACCRealm.java
(original)
+++ geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/main/java/org/apache/geronimo/tomcat/security/jacc/JACCRealm.java
Fri Oct 22 10:11:58 2010
@@ -52,15 +52,15 @@ public class JACCRealm implements Realm 
         return old;
     }
 
-    @Override
+    /*@Override
     @Deprecated
     public boolean hasRole(Principal principal, String role) {
         AccessControlContext acc = ContextManager.getCurrentContext();
         String name = currentRequestWrapperName.get();
 
-        /**
+        *//**
          * JACC v1.0 secion B.19
-         */
+         *//*
         if (name == null || name.equals("jsp")) {
             name = "";
         }
@@ -70,7 +70,7 @@ public class JACCRealm implements Realm 
         } catch (AccessControlException e) {
             return false;
         }
-    }
+    }*/
 
     @Override
     public boolean hasRole(Wrapper wrapper, Principal principal, String role) {

Modified: geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/test/java/org/apache/geronimo/tomcat/AbstractWebModuleTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/test/java/org/apache/geronimo/tomcat/AbstractWebModuleTest.java?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/test/java/org/apache/geronimo/tomcat/AbstractWebModuleTest.java
(original)
+++ geronimo/server/trunk/plugins/tomcat/geronimo-tomcat7/src/test/java/org/apache/geronimo/tomcat/AbstractWebModuleTest.java
Fri Oct 22 10:11:58 2010
@@ -27,6 +27,7 @@ import java.util.Set;
 
 import javax.security.auth.login.LoginException;
 import javax.security.jacc.PolicyContextException;
+import javax.servlet.jsp.JspFactory;
 import javax.transaction.TransactionManager;
 
 import org.apache.felix.karaf.jaas.boot.ProxyLoginModule;
@@ -93,6 +94,8 @@ public abstract class AbstractWebModuleT
 
     protected TomcatWebAppContext setUpInsecureAppContext(String relativeWebAppRoot, URL
configurationBaseURL, SecurityHolder securityHolder, RunAsSource runAsSource, ObjectRetriever
tomcatRealm, ValveGBean valveChain, WebAppInfo webAppInfo) throws Exception {
         configurationBaseURL = cl.getResource("deployables/");
+        //Setup default JSP Factory
+        Class.forName("org.apache.jasper.compiler.JspRuntimeContext");
         URI locationURI = configurationBaseURL.toURI().resolve(relativeWebAppRoot);
         MockBundleContext bundleContext = new MockBundleContext(getClass().getClassLoader(),
locationURI.toString(), new HashMap<Artifact, ConfigurationData>(), null);
         bundle = bundleContext.getBundle();

Modified: geronimo/server/trunk/plugins/tomcat/tomcat7/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/tomcat/tomcat7/src/main/history/dependencies.xml?rev=1026274&r1=1026273&r2=1026274&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/tomcat/tomcat7/src/main/history/dependencies.xml (original)
+++ geronimo/server/trunk/plugins/tomcat/tomcat7/src/main/history/dependencies.xml Fri Oct
22 10:11:58 2010
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<plugin-artifact xmlns:ns2="http://geronimo.apache.org/xml/ns/attributes-1.2" xmlns="http://geronimo.apache.org/xml/ns/plugins-1.3">
+<plugin-artifact xmlns="http://geronimo.apache.org/xml/ns/plugins-1.3" xmlns:ns2="http://geronimo.apache.org/xml/ns/attributes-1.2">
     <module-id>
         <groupId>org.apache.geronimo.configs</groupId>
         <artifactId>tomcat7</artifactId>
@@ -7,11 +7,31 @@
         <type>car</type>
     </module-id>
     <dependency>
+        <groupId>commons-beanutils</groupId>
+        <artifactId>commons-beanutils</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>commons-collections</groupId>
+        <artifactId>commons-collections</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
         <groupId>org.apache.geronimo.bundles</groupId>
         <artifactId>castor</artifactId>
         <type>jar</type>
     </dependency>
     <dependency>
+        <groupId>org.apache.geronimo.bundles</groupId>
+        <artifactId>commons-digester</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.bundles</groupId>
+        <artifactId>commons-discovery</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
         <groupId>org.apache.geronimo.configs</groupId>
         <artifactId>j2ee-server</artifactId>
         <type>car</type>
@@ -63,6 +83,11 @@
     </dependency>
     <dependency>
         <groupId>org.apache.geronimo.modules</groupId>
+        <artifactId>geronimo-openwebbeans</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.modules</groupId>
         <artifactId>geronimo-tomcat7</artifactId>
         <type>jar</type>
     </dependency>
@@ -83,17 +108,22 @@
     </dependency>
     <dependency>
         <groupId>org.apache.geronimo.specs</groupId>
-        <artifactId>geronimo-annotation_1.1_spec</artifactId>
+        <artifactId>geronimo-jaxr_1.0_spec</artifactId>
         <type>jar</type>
     </dependency>
     <dependency>
         <groupId>org.apache.geronimo.specs</groupId>
-        <artifactId>geronimo-jaxr_1.0_spec</artifactId>
+        <artifactId>geronimo-jaxws_2.2_spec</artifactId>
         <type>jar</type>
     </dependency>
     <dependency>
-        <groupId>org.apache.geronimo.specs</groupId>
-        <artifactId>geronimo-jaxws_2.2_spec</artifactId>
+        <groupId>org.apache.myfaces.core</groupId>
+        <artifactId>myfaces-api</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.myfaces.core</groupId>
+        <artifactId>myfaces-impl</artifactId>
         <type>jar</type>
     </dependency>
     <dependency>
@@ -102,6 +132,31 @@
         <type>jar</type>
     </dependency>
     <dependency>
+        <groupId>org.apache.openwebbeans</groupId>
+        <artifactId>openwebbeans-jsf</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.openwebbeans</groupId>
+        <artifactId>openwebbeans-osgi</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.openwebbeans</groupId>
+        <artifactId>openwebbeans-web</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.servicemix.bundles</groupId>
+        <artifactId>org.apache.servicemix.bundles.commons-codec</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.servicemix.bundles</groupId>
+        <artifactId>org.apache.servicemix.bundles.dom4j</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
         <groupId>org.apache.servicemix.bundles</groupId>
         <artifactId>org.apache.servicemix.bundles.wsdl4j</artifactId>
         <type>jar</type>



Mime
View raw message