cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject cxf git commit: Minor update to OAuth2 digest code verifier
Date Thu, 18 Dec 2014 13:08:08 GMT
Repository: cxf
Updated Branches:
  refs/heads/master ba0020228 -> 9d1aad519


Minor update to OAuth2 digest code verifier


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

Branch: refs/heads/master
Commit: 9d1aad5195e808d0cd5ca1bfa44e1c842ba848c3
Parents: ba00202
Author: Sergey Beryozkin <sberyozkin@talend.com>
Authored: Thu Dec 18 13:07:51 2014 +0000
Committer: Sergey Beryozkin <sberyozkin@talend.com>
Committed: Thu Dec 18 13:07:51 2014 +0000

----------------------------------------------------------------------
 .../cxf/rs/security/oauth2/grants/code/DigestCodeVerifier.java   | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/9d1aad51/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/grants/code/DigestCodeVerifier.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/grants/code/DigestCodeVerifier.java
b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/grants/code/DigestCodeVerifier.java
index 371e907..61661e9 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/grants/code/DigestCodeVerifier.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/grants/code/DigestCodeVerifier.java
@@ -26,9 +26,7 @@ public class DigestCodeVerifier implements CodeVerifierTransformer {
     public String transformCodeVerifier(String codeVerifier) {
         byte[] digest = MessageDigestUtils.createDigest(codeVerifier, 
                                                         MessageDigestUtils.ALGO_SHA_256);
-        int length = digest.length > 128 / 8 ? 128 / 8 : digest.length;
-        
-        return Base64UrlUtility.encodeChunk(digest, 0, length);
+        return Base64UrlUtility.encode(digest);
     }
 
     


Mime
View raw message