Fixing merge

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

Branch: refs/heads/3.0.x-fixes
Commit: d59b780fc729b8421090534c827cfd039b79e9bf
Parents: b51eca6
Author: Colm O hEigeartaigh <cohei...@apache.org>
Authored: Mon Nov 30 13:13:01 2015 +0000
Committer: Colm O hEigeartaigh <cohei...@apache.org>
Committed: Mon Nov 30 13:13:01 2015 +0000

----------------------------------------------------------------------
 .../oauth2/grants/saml/Saml2BearerGrantHandler.java     | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/d59b780f/rt/rs/security/oauth-parent/oauth2-saml/src/main/java/org/apache/cxf/rs/security/oauth2/grants/saml/Saml2BearerGrantHandler.java
----------------------------------------------------------------------
diff --git 
a/rt/rs/security/oauth-parent/oauth2-saml/src/main/java/org/apache/cxf/rs/security/oauth2/grants/saml/Saml2BearerGrantHandler.java
 
b/rt/rs/security/oauth-parent/oauth2-saml/src/main/java/org/apache/cxf/rs/security/oauth2/grants/saml/Saml2BearerGrantHandler.java
index 3ac98f7..b22f508 100644
--- 
a/rt/rs/security/oauth-parent/oauth2-saml/src/main/java/org/apache/cxf/rs/security/oauth2/grants/saml/Saml2BearerGrantHandler.java
+++ 
b/rt/rs/security/oauth-parent/oauth2-saml/src/main/java/org/apache/cxf/rs/security/oauth2/grants/saml/Saml2BearerGrantHandler.java
@@ -38,6 +38,7 @@ import org.apache.cxf.common.util.Base64Exception;
 import org.apache.cxf.common.util.Base64UrlUtility;
 import org.apache.cxf.jaxrs.utils.HttpUtils;
 import org.apache.cxf.message.Message;
+import org.apache.cxf.message.MessageUtils;
 import org.apache.cxf.phase.PhaseInterceptorChain;
 import org.apache.cxf.rs.security.common.CryptoLoader;
 import org.apache.cxf.rs.security.common.SecurityUtils;
@@ -63,6 +64,7 @@ import org.apache.wss4j.common.saml.SamlAssertionWrapper;
 import org.apache.wss4j.dom.WSDocInfo;
 import org.apache.wss4j.dom.WSSConfig;
 import org.apache.wss4j.dom.handler.RequestData;
+import org.apache.wss4j.dom.handler.WSHandlerConstants;
 import org.apache.wss4j.dom.saml.WSSSAMLKeyInfoProcessor;
 import org.apache.wss4j.dom.validate.Credential;
 import org.apache.wss4j.dom.validate.SamlAssertionValidator;
@@ -185,14 +187,8 @@ public class Saml2BearerGrantHandler extends 
AbstractGrantHandler {
                     throw new 
OAuthServiceException(OAuthConstants.INVALID_GRANT);
                 }
                 
-                boolean enableRevocation = false;
-                String enableRevocationStr = 
-                    
(String)org.apache.cxf.rt.security.utils.SecurityUtils.getSecurityPropertyValue(
-                        SecurityConstants.ENABLE_REVOCATION, message);
-                if (enableRevocationStr != null) {
-                    enableRevocation = 
Boolean.parseBoolean(enableRevocationStr);
-                }
-                data.setEnableRevocation(enableRevocation);
+                data.setEnableRevocation(MessageUtils.isTrue(
+                    
message.getContextualProperty(WSHandlerConstants.ENABLE_REVOCATION)));
                 
                 Signature sig = assertion.getSignature();
                 WSDocInfo docInfo = new 
WSDocInfo(sig.getDOM().getOwnerDocument());

Reply via email to