You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by se...@apache.org on 2014/06/05 16:12:10 UTC

[1/2] git commit: Defaulting to A256GSM JWT name if Java AES name is provided

Repository: cxf
Updated Branches:
  refs/heads/master 68c318678 -> 63e9732af


Defaulting to A256GSM JWT name if Java AES name is provided


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

Branch: refs/heads/master
Commit: 95a6d1c0d97ac5aafb5c7f819d9cb120ea04a9e5
Parents: e44fba7
Author: Sergey Beryozkin <sb...@talend.com>
Authored: Thu Jun 5 15:11:33 2014 +0100
Committer: Sergey Beryozkin <sb...@talend.com>
Committed: Thu Jun 5 15:11:33 2014 +0100

----------------------------------------------------------------------
 .../org/apache/cxf/rs/security/oauth2/jwe/RSAJweEncryptor.java     | 2 +-
 .../main/java/org/apache/cxf/rs/security/oauth2/jwt/Algorithm.java | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/95a6d1c0/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwe/RSAJweEncryptor.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwe/RSAJweEncryptor.java b/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwe/RSAJweEncryptor.java
index 9be12a1..22c2f7e 100644
--- a/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwe/RSAJweEncryptor.java
+++ b/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwe/RSAJweEncryptor.java
@@ -40,7 +40,7 @@ public class RSAJweEncryptor extends JweEncryptor {
              secretKey.getEncoded(), iv, DEFAULT_AUTH_TAG_LENGTH, true);
     }
     public RSAJweEncryptor(RSAPublicKey publicKey, SecretKey secretKey, byte[] iv) {
-        this(publicKey, secretKey, Algorithm.stripAlgoProperties(secretKey.getAlgorithm()), iv);
+        this(publicKey, secretKey, Algorithm.toJwtName(secretKey.getAlgorithm()), iv);
     }
     
     public RSAJweEncryptor(RSAPublicKey publicKey, JweHeaders headers, byte[] cek, byte[] iv, 

http://git-wip-us.apache.org/repos/asf/cxf/blob/95a6d1c0/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwt/Algorithm.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwt/Algorithm.java b/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwt/Algorithm.java
index c675016..8e30195 100644
--- a/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwt/Algorithm.java
+++ b/rt/rs/security/oauth-parent/oauth2-jwt/src/main/java/org/apache/cxf/rs/security/oauth2/jwt/Algorithm.java
@@ -49,6 +49,7 @@ public enum Algorithm {
     public static final String RSA_OAEP_ALGO_JAVA = "RSA/ECB/OAEPWithSHA-1AndMGF1Padding";
     public static final String RSA_OAEP_256_ALGO_JAVA = "RSA/ECB/OAEPWithSHA-256AndMGF1Padding";
     public static final String RSA_1_5_ALGO_JAVA = "RSA/ECB/PKCS1Padding";
+    public static final String AES_ALGO_JAVA = "AES";
     public static final String A256GCM_ALGO_JAVA = "AES/GCM/NoPadding";
     
     private static final Map<String, String> JAVA_TO_JWT_NAMES;
@@ -65,6 +66,7 @@ public enum Algorithm {
         JAVA_TO_JWT_NAMES.put(RSA_OAEP_256_ALGO_JAVA, JwtConstants.RSA_OAEP_256_ALGO);
         JAVA_TO_JWT_NAMES.put(RSA_1_5_ALGO_JAVA, JwtConstants.RSA_1_5_ALGO);
         JAVA_TO_JWT_NAMES.put(A256GCM_ALGO_JAVA, JwtConstants.A256GCM_ALGO);
+        JAVA_TO_JWT_NAMES.put(AES_ALGO_JAVA, JwtConstants.A256GCM_ALGO);
         JWT_TO_JAVA_NAMES = new HashMap<String, String>();
         JWT_TO_JAVA_NAMES.put(JwtConstants.HMAC_SHA_256_ALGO, HMAC_SHA_256_JAVA);
         JWT_TO_JAVA_NAMES.put(JwtConstants.HMAC_SHA_384_ALGO, HMAC_SHA_384_JAVA);


[2/2] git commit: Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/cxf

Posted by se...@apache.org.
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/cxf


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

Branch: refs/heads/master
Commit: 63e9732af50a7db6c06620d9375e5180a9ce3f62
Parents: 95a6d1c 68c3186
Author: Sergey Beryozkin <sb...@talend.com>
Authored: Thu Jun 5 15:11:58 2014 +0100
Committer: Sergey Beryozkin <sb...@talend.com>
Committed: Thu Jun 5 15:11:58 2014 +0100

----------------------------------------------------------------------
 .../org/apache/cxf/transport/jms/JMSConfigFactory.java    |  4 ++--
 .../org/apache/cxf/transport/jms/JMSConfiguration.java    | 10 +++++-----
 .../java/org/apache/cxf/transport/jms/JMSFactory.java     |  4 ++--
 .../org/apache/cxf/transport/jms/uri/JMSEndpoint.java     | 10 ++++++++++
 4 files changed, 19 insertions(+), 9 deletions(-)
----------------------------------------------------------------------