Author: coheigea
Date: Fri Jul  3 10:26:29 2009
New Revision: 790849

URL: http://svn.apache.org/viewvc?rev=790849&view=rev
Log:
Backmerged to 1_5_fixes.

Modified:
    
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/handler/WSHandler.java
    
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/util/WSSecurityUtil.java

Modified: 
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/handler/WSHandler.java
URL: 
http://svn.apache.org/viewvc/webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/handler/WSHandler.java?rev=790849&r1=790848&r2=790849&view=diff
==============================================================================
--- 
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/handler/WSHandler.java
 (original)
+++ 
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/handler/WSHandler.java
 Fri Jul  3 10:26:29 2009
@@ -93,8 +93,9 @@
             wssConfig = WSSConfig.getNewInstance();
         }
 
+        boolean enableSigConf = decodeEnableSignatureConfirmation(reqData);
         wssConfig.setEnableSignatureConfirmation(
-            decodeEnableSignatureConfirmation(reqData)
+            enableSigConf || ((doAction & WSConstants.SC) != 0)
         );
 
         wssConfig.setPrecisionInMilliSeconds(
@@ -253,8 +254,9 @@
         if (wssConfig == null) {
             wssConfig = WSSConfig.getNewInstance();
         }
+        boolean enableSigConf = decodeEnableSignatureConfirmation(reqData);
         wssConfig.setEnableSignatureConfirmation(
-            decodeEnableSignatureConfirmation(reqData)
+            enableSigConf || ((doAction & WSConstants.SC) != 0)
         );
         wssConfig.setTimeStampStrict(decodeTimestampStrict(reqData));
         
wssConfig.setHandleCustomPasswordTypes(decodeCustomPasswordTypes(reqData));

Modified: 
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/util/WSSecurityUtil.java
URL: 
http://svn.apache.org/viewvc/webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/util/WSSecurityUtil.java?rev=790849&r1=790848&r2=790849&view=diff
==============================================================================
--- 
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/util/WSSecurityUtil.java
 (original)
+++ 
webservices/wss4j/branches/1_5_x-fixes/src/org/apache/ws/security/util/WSSecurityUtil.java
 Fri Jul  3 10:26:29 2009
@@ -879,6 +879,9 @@
             } else if (single[i].equals(WSHandlerConstants.SIGN_WITH_UT_KEY)) {
                 doAction |= WSConstants.UT_SIGN;
                 actions.add(new Integer(WSConstants.UT_SIGN));
+            } else if 
(single[i].equals(WSHandlerConstants.ENABLE_SIGNATURE_CONFIRMATION)) {
+                doAction |= WSConstants.SC;
+                actions.add(new Integer(WSConstants.SC));
             } else {
                 throw new WSSecurityException(
                     "Unknown action defined: " + single[i]
@@ -936,6 +939,9 @@
             } else if (single[i].equals(WSHandlerConstants.SIGN_WITH_UT_KEY)) {
                 doAction |= WSConstants.UT_SIGN;
                 actions.add(new Integer(WSConstants.UT_SIGN));
+            } else if 
(single[i].equals(WSHandlerConstants.ENABLE_SIGNATURE_CONFIRMATION)) {
+                doAction |= WSConstants.SC;
+                actions.add(new Integer(WSConstants.SC));
             } else {
                 try {
                     int parsedAction = Integer.parseInt(single[i]);



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to