cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cohei...@apache.org
Subject cxf git commit: [CXF-6473] - Double signatures while using AsymmetricBindingHandle
Date Wed, 24 Jun 2015 15:59:02 GMT
Repository: cxf
Updated Branches:
  refs/heads/3.0.x-fixes de570e564 -> 273351c1d


[CXF-6473] - Double signatures while using AsymmetricBindingHandle


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/273351c1
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/273351c1
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/273351c1

Branch: refs/heads/3.0.x-fixes
Commit: 273351c1d48bc27018610dba1218551889e89630
Parents: de570e5
Author: Colm O hEigeartaigh <coheigea@apache.org>
Authored: Wed Jun 24 16:53:12 2015 +0100
Committer: Colm O hEigeartaigh <coheigea@apache.org>
Committed: Wed Jun 24 16:53:52 2015 +0100

----------------------------------------------------------------------
 .../security/wss4j/policyhandlers/AsymmetricBindingHandler.java | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/273351c1/rt/ws/security/src/main/java/org/apache/cxf/ws/security/wss4j/policyhandlers/AsymmetricBindingHandler.java
----------------------------------------------------------------------
diff --git a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/wss4j/policyhandlers/AsymmetricBindingHandler.java
b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/wss4j/policyhandlers/AsymmetricBindingHandler.java
index 83c3b50..82f99de 100644
--- a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/wss4j/policyhandlers/AsymmetricBindingHandler.java
+++ b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/wss4j/policyhandlers/AsymmetricBindingHandler.java
@@ -172,6 +172,8 @@ public class AsymmetricBindingHandler extends AbstractBindingBuilder {
             }
             addSupportingTokens(sigs);
             
+            sigs.addAll(this.getSignedParts(null));
+            
             if (isRequestor() && initiatorWrapper != null) {
                 doSignature(initiatorWrapper, sigs, attached);
                 doEndorse();
@@ -326,7 +328,7 @@ public class AsymmetricBindingHandler extends AbstractBindingBuilder {
         List<WSEncryptionPart> encrParts = null;
         try {
             encrParts = getEncryptedParts();
-            //Signed parts are determined before encryption because encrypted signed  headers
+            //Signed parts are determined before encryption because encrypted signed headers
             //will not be included otherwise
             sigParts.addAll(this.getSignedParts(null));
         } catch (SOAPException ex) {
@@ -601,7 +603,6 @@ public class AsymmetricBindingHandler extends AbstractBindingBuilder {
         }
         
         AbstractToken sigToken = wrapper.getToken();
-        sigParts.addAll(this.getSignedParts(null));
         if (sigParts.isEmpty()) {
             // Add the BST to the security header if required
             if (!attached && isTokenRequired(sigToken.getIncludeTokenType())) {


Mime
View raw message