Author: azeez
Date: Thu Jan 17 07:26:43 2008
New Revision: 12423

Log:

Allow installation of WSAS even if a JDK is not present. A JRE will suffice.
POX Sec handler should work only for HTTPS REST requests



Modified:
   
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/AbstractAppServerInstaller.java
   
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/TomcatInstaller.java
   
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/security/pox/POXSecurityHandler.java

Modified: 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/AbstractAppServerInstaller.java
==============================================================================
--- 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/AbstractAppServerInstaller.java
   (original)
+++ 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/AbstractAppServerInstaller.java
   Thu Jan 17 07:26:43 2008
@@ -142,7 +142,8 @@
         }
     }
 
-    protected void copyToolsJAR(String toDir) throws InstallationException {
+    //TODO: Some production servers do not run on boxes with JDK only JRE 
hence do not look for tools jar
+    /*protected void copyToolsJAR(String toDir) throws InstallationException {
         try {
             File libDir = new File(toDir);
             System.out.println("Copying library containing javac compiler 
(com.sun.tools.javac.Main) to \"" +
@@ -194,7 +195,7 @@
             System.err.println(" " + msg);
             throw new InstallationException(msg, e);
         }
-    }
+    }*/
 
     protected void copyWsasWAR(String webappsDir) throws InstallationException 
{
         File webappDir = new File(webappsDir);

Modified: 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/TomcatInstaller.java
==============================================================================
--- 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/TomcatInstaller.java
      (original)
+++ 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/installer/TomcatInstaller.java
      Thu Jan 17 07:26:43 2008
@@ -154,11 +154,11 @@
         if (version.equals(TOMCAT_6_X)) {
             copyDerbyJAR(serverHome + File.separator + File.separator + "lib");
             copyLog4jJAR(serverHome + File.separator + File.separator + "lib");
-            copyToolsJAR(serverHome + File.separator + File.separator + "lib");
+//            copyToolsJAR(serverHome + File.separator + File.separator + 
"lib");  //TODO: Some production servers do not run on boxes with JDK only JRE 
hence do not look for tools jar
         } else {
             copyDerbyJAR(serverHome + File.separator + "common" + 
File.separator + "lib");
             copyLog4jJAR(serverHome + File.separator + "common" + 
File.separator + "lib");
-            copyToolsJAR(serverHome + File.separator + "common" + 
File.separator + "lib");
+//            copyToolsJAR(serverHome + File.separator + "common" + 
File.separator + "lib"); //TODO: Some production servers do not run on boxes 
with JDK only JRE hence do not look for tools jar
         }
 
         if (isServerXMLReplaced) {

Modified: 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/security/pox/POXSecurityHandler.java
==============================================================================
--- 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/security/pox/POXSecurityHandler.java
        (original)
+++ 
branches/wsas/java/2.2/wsas/java/modules/core/src/org/wso2/wsas/security/pox/POXSecurityHandler.java
        Thu Jan 17 07:26:43 2008
@@ -77,7 +77,7 @@
     public InvocationResponse invoke(MessageContext msgCtx) throws AxisFault {
 
         //If this is not a REST/POX message simply return
-        if (!msgCtx.isDoingREST()) {
+        if (!msgCtx.isDoingREST() || 
!msgCtx.getIncomingTransportName().equals("https")) { // This handler will 
interecept REST requests only arriving via HTTPS
             return InvocationResponse.CONTINUE;
         }
 
@@ -98,8 +98,6 @@
                 return InvocationResponse.CONTINUE;
             }
         } else {
-              // Not all REST request needs authentication and its not 
acceptable to log a EARN when i do not need security
-//            log.warn("Service " + service.getName() + " is not persisted.");
             return InvocationResponse.CONTINUE;
         }
 

_______________________________________________
Wsas-java-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/wsas-java-dev

Reply via email to