You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by ru...@apache.org on 2006/08/02 07:00:07 UTC

svn commit: r427895 - in /webservices/axis2/trunk/java/modules/integration: test-resources/rahas/ test/org/apache/rahas/

Author: ruchithf
Date: Tue Aug  1 22:00:06 2006
New Revision: 427895

URL: http://svn.apache.org/viewvc?rev=427895&view=rev
Log:
Adjusted the rahas test configurations to be similar to that of SX-interop scenario configs


Modified:
    webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s1-services.xml
    webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s3-services.xml
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/PWCallback.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKTest.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKV1205Test.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenTest.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerTest.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerV1205Test.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKTest.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKV1205Test.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenV1205Test.java
    webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/TestClient.java

Modified: webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s1-services.xml
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s1-services.xml?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s1-services.xml (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s1-services.xml Tue Aug  1 22:00:06 2006
@@ -31,15 +31,19 @@
 	
 	<parameter name="InflowSecurity">
       <action>
-        <items>Timestamp Signature</items>
+        <items>Signature Encrypt Timestamp</items>
         <signaturePropFile>issuer.properties</signaturePropFile>
+		<decryptionPropFile>issuer.properties</decryptionPropFile>
+		<passwordCallbackClass xmlns="">org.apache.rahas.PWCallback</passwordCallbackClass>
       </action>
     </parameter>
 
     <parameter name="OutflowSecurity">
       <action>
-        <items>Timestamp Signature</items>
+        <items>Signature Encrypt Timestamp</items>
         <user>ip</user>
+		<encryptionUser>useReqSigCert</encryptionUser>
+		<signatureKeyIdentifier>DirectReference</signatureKeyIdentifier>
         <signaturePropFile xmlns="">issuer.properties</signaturePropFile>
 	    <passwordCallbackClass xmlns="">org.apache.rahas.PWCallback</passwordCallbackClass>
       </action>

Modified: webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s3-services.xml
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s3-services.xml?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s3-services.xml (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/rahas/s3-services.xml Tue Aug  1 22:00:06 2006
@@ -31,7 +31,7 @@
 	
 	<parameter name="InflowSecurity">
       <action>
-        <items>Timestamp UsernameToken</items>
+        <items>UsernameToken Timestamp</items>
 		<passwordCallbackClass xmlns="">org.apache.rahas.PWCallback</passwordCallbackClass>
       </action>
     </parameter>

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/PWCallback.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/PWCallback.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/PWCallback.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/PWCallback.java Tue Aug  1 22:00:06 2006
@@ -119,7 +119,13 @@
                         return;
 
                 	}
+                    
+                    if(pc.getIdentifer().equals("joe") && pc.getPassword().equals("eoj")) {
 
+                        return;
+
+                    }
+                    
                     if (pc.getPassword().equals("sirhC")) {
 
                         return;
@@ -159,6 +165,10 @@
                 } else if(pc.getIdentifer().equals("Ron")) {
 
                     pc.setPassword("noR");
+
+                } else if(pc.getIdentifer().equals("joe")) {
+
+                    pc.setPassword("eoj");
 
                 } else if(pc.getIdentifer().equals("ip")) {
                     

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKTest.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKTest.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKTest.java Tue Aug  1 22:00:06 2006
@@ -39,8 +39,9 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp Signature");
+        ofc.setActionItems("Signature Encrypt Timestamp");
         ofc.setUser("alice");
+        ofc.setEncryptionUser("ip");
         ofc.setSignaturePropFile("rahas-sec.properties");
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
         return ofc;
@@ -49,7 +50,7 @@
     public InflowConfiguration getClientInflowConfiguration() {
         InflowConfiguration ifc = new InflowConfiguration();
 
-        ifc.setActionItems("Timestamp Signature");
+        ifc.setActionItems("Signature Encrypt Timestamp");
         ifc.setPasswordCallbackClass(PWCallback.class.getName());
         ifc.setSignaturePropFile("rahas-sec.properties");
         

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKV1205Test.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKV1205Test.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKV1205Test.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenCertForHoKV1205Test.java Tue Aug  1 22:00:06 2006
@@ -17,6 +17,7 @@
 package org.apache.rahas;
 
 import org.apache.axiom.om.OMElement;
+import org.apache.rampart.handler.WSSHandlerConstants;
 import org.apache.rampart.handler.config.InflowConfiguration;
 import org.apache.rampart.handler.config.OutflowConfiguration;
 import org.opensaml.XML;
@@ -52,9 +53,11 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp Signature");
+        ofc.setActionItems("Signature Encrypt Timestamp");
         ofc.setUser("alice");
+        ofc.setEncryptionUser("ip");
         ofc.setSignaturePropFile("rahas-sec.properties");
+        ofc.setSignatureKeyIdentifier(WSSHandlerConstants.BST_DIRECT_REFERENCE);
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
         return ofc;
     }
@@ -62,7 +65,7 @@
     public InflowConfiguration getClientInflowConfiguration() {
         InflowConfiguration ifc = new InflowConfiguration();
 
-        ifc.setActionItems("Timestamp Signature");
+        ifc.setActionItems("Signature Encrypt Timestamp");
         ifc.setPasswordCallbackClass(PWCallback.class.getName());
         ifc.setSignaturePropFile("rahas-sec.properties");
         

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenTest.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenTest.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenTest.java Tue Aug  1 22:00:06 2006
@@ -43,7 +43,7 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp Signature");
+        ofc.setActionItems("Signature Encrypt Timestamp");
         ofc.setUser("alice");
         ofc.setSignaturePropFile("rahas-sec.properties");
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
@@ -53,7 +53,7 @@
     public InflowConfiguration getClientInflowConfiguration() {
         InflowConfiguration ifc = new InflowConfiguration();
 
-        ifc.setActionItems("Timestamp Signature");
+        ifc.setActionItems("Signature Encrypt Timestamp");
         ifc.setPasswordCallbackClass(PWCallback.class.getName());
         ifc.setSignaturePropFile("rahas-sec.properties");
         

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerTest.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerTest.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerTest.java Tue Aug  1 22:00:06 2006
@@ -17,7 +17,6 @@
 package org.apache.rahas;
 
 import org.apache.axiom.om.OMElement;
-import org.apache.axis2.security.sc.PWCallback;
 import org.apache.rampart.handler.config.InflowConfiguration;
 import org.apache.rampart.handler.config.OutflowConfiguration;
 import org.opensaml.XML;
@@ -58,8 +57,8 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp UsernameToken");
-        ofc.setUser("Ron");
+        ofc.setActionItems("UsernameToken Timestamp");
+        ofc.setUser("joe");
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
         return ofc;
     }

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerV1205Test.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerV1205Test.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerV1205Test.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForBearerV1205Test.java Tue Aug  1 22:00:06 2006
@@ -56,8 +56,8 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp UsernameToken");
-        ofc.setUser("Ron");
+        ofc.setActionItems("UsernameToken Timestamp");
+        ofc.setUser("joe");
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
         return ofc;
     }

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKTest.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKTest.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKTest.java Tue Aug  1 22:00:06 2006
@@ -17,7 +17,6 @@
 package org.apache.rahas;
 
 import org.apache.axiom.om.OMElement;
-import org.apache.axis2.security.sc.PWCallback;
 import org.apache.rampart.handler.config.InflowConfiguration;
 import org.apache.rampart.handler.config.OutflowConfiguration;
 import org.opensaml.XML;
@@ -54,8 +53,8 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp UsernameToken");
-        ofc.setUser("Ron");
+        ofc.setActionItems("UsernameToken Timestamp");
+        ofc.setUser("joe");
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
         return ofc;
     }

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKV1205Test.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKV1205Test.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKV1205Test.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenUTForHoKV1205Test.java Tue Aug  1 22:00:06 2006
@@ -17,9 +17,9 @@
 package org.apache.rahas;
 
 import org.apache.axiom.om.OMElement;
-import org.apache.rahas.PWCallback;
 import org.apache.rampart.handler.config.InflowConfiguration;
 import org.apache.rampart.handler.config.OutflowConfiguration;
+import org.apache.ws.security.WSConstants;
 import org.opensaml.XML;
 
 import javax.xml.namespace.QName;
@@ -57,8 +57,9 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp UsernameToken");
-        ofc.setUser("Ron");
+        ofc.setActionItems("UsernameToken Timestamp");
+        ofc.setUser("joe");
+        ofc.setPasswordType(WSConstants.PW_TEXT);
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
         return ofc;
     }

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenV1205Test.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenV1205Test.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenV1205Test.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/RahasSAMLTokenV1205Test.java Tue Aug  1 22:00:06 2006
@@ -59,7 +59,7 @@
     public OutflowConfiguration getClientOutflowConfiguration() {
         OutflowConfiguration ofc = new OutflowConfiguration();
 
-        ofc.setActionItems("Timestamp Signature");
+        ofc.setActionItems("Signature Encrypt Timestamp");
         ofc.setUser("alice");
         ofc.setSignaturePropFile("rahas-sec.properties");
         ofc.setPasswordCallbackClass(PWCallback.class.getName());
@@ -69,7 +69,7 @@
     public InflowConfiguration getClientInflowConfiguration() {
         InflowConfiguration ifc = new InflowConfiguration();
 
-        ifc.setActionItems("Timestamp Signature");
+        ifc.setActionItems("Signature Encrypt Timestamp");
         ifc.setPasswordCallbackClass(PWCallback.class.getName());
         ifc.setSignaturePropFile("rahas-sec.properties");
         

Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/TestClient.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/TestClient.java?rev=427895&r1=427894&r2=427895&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/TestClient.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/rahas/TestClient.java Tue Aug  1 22:00:06 2006
@@ -62,6 +62,7 @@
             ServiceClient serviceClient = new ServiceClient(configContext, null);
             Options options = new Options();
             options.setTo(new EndpointReference("http://127.0.0.1:" + port + "/axis2/services/SecureService"));
+//            options.setTo(new EndpointReference("http://127.0.0.1:" + 9090 + "/axis2/services/UTSAMLHoK"));
             options.setTransportInProtocol(Constants.TRANSPORT_HTTP);
             options.setAction(this.getRequestAction());
             



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org