cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1368176 - /cxf/branches/2.4.x-fixes/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/STSClient.java
Date Wed, 01 Aug 2012 18:30:10 GMT
Author: dkulp
Date: Wed Aug  1 18:30:10 2012
New Revision: 1368176

URL: http://svn.apache.org/viewvc?rev=1368176&view=rev
Log:
Merged revisions 1368167 via  git cherry-pick from
https://svn.apache.org/repos/asf/cxf/branches/2.5.x-fixes

........
  r1368167 | dkulp | 2012-08-01 14:28:16 -0400 (Wed, 01 Aug 2012) | 18 lines

  Merged revisions 1368113 via  git cherry-pick from
  https://svn.apache.org/repos/asf/cxf/branches/2.6.x-fixes

  ........
    r1368113 | dkulp | 2012-08-01 12:42:34 -0400 (Wed, 01 Aug 2012) | 10 lines

    Merged revisions 1368101 via  git cherry-pick from
    https://svn.apache.org/repos/asf/cxf/trunk

    ........
      r1368101 | dkulp | 2012-08-01 12:24:20 -0400 (Wed, 01 Aug 2012) | 2 lines

      [CXF-4450] Evaluate the wsam:Action attributes as well

    ........

  ........

........

Modified:
    cxf/branches/2.4.x-fixes/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/STSClient.java

Modified: cxf/branches/2.4.x-fixes/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/STSClient.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/STSClient.java?rev=1368176&r1=1368175&r2=1368176&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/STSClient.java
(original)
+++ cxf/branches/2.4.x-fixes/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/STSClient.java
Wed Aug  1 18:30:10 2012
@@ -462,7 +462,17 @@ public class STSClient implements Config
         BindingInfo bi = client.getEndpoint().getBinding().getBindingInfo();
         for (BindingOperationInfo boi : bi.getOperations()) {
             SoapOperationInfo soi = boi.getExtensor(SoapOperationInfo.class);
-            if (soi != null && soi.getAction() != null && soi.getAction().endsWith(suffix))
{
+            String soapAction = soi != null ? soi.getAction() : null;
+            Object o  = boi.getOperationInfo().getInput()
+                    .getExtensionAttribute(new QName("http://www.w3.org/2007/05/addressing/metadata",
+                                                     "Action"));
+            if (o instanceof QName) {
+                o = ((QName)o).getLocalPart();
+            }
+            String wsamAction = o == null ? null : o.toString();
+            
+            if ((soapAction != null && soapAction.endsWith(suffix))
+                || (wsamAction != null && wsamAction.endsWith(suffix))) {
                 PolicyEngine pe = bus.getExtension(PolicyEngine.class);
                 Conduit conduit = client.getConduit();
                 EffectivePolicy effectivePolicy = pe.getEffectiveClientRequestPolicy(client.getEndpoint()



Mime
View raw message