cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject cxf git commit: Adding a description property to OOBAuthorizationResponse
Date Mon, 16 Nov 2015 12:43:58 GMT
Repository: cxf
Updated Branches:
  refs/heads/3.1.x-fixes 3832cdfc4 -> ed0421182


Adding a description property to OOBAuthorizationResponse


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

Branch: refs/heads/3.1.x-fixes
Commit: ed0421182de3256653710893a770447cdc21bab0
Parents: 3832cdf
Author: Sergey Beryozkin <sberyozkin@gmail.com>
Authored: Mon Nov 16 12:41:59 2015 +0000
Committer: Sergey Beryozkin <sberyozkin@gmail.com>
Committed: Mon Nov 16 12:42:58 2015 +0000

----------------------------------------------------------------------
 .../oauth2/common/OOBAuthorizationResponse.java   | 18 +++++++++---------
 .../services/AuthorizationCodeGrantService.java   |  1 +
 2 files changed, 10 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/ed042118/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OOBAuthorizationResponse.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OOBAuthorizationResponse.java
b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OOBAuthorizationResponse.java
index e1267a3..bc1a4aa 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OOBAuthorizationResponse.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OOBAuthorizationResponse.java
@@ -22,6 +22,7 @@ package org.apache.cxf.rs.security.oauth2.common;
 public class OOBAuthorizationResponse {
     private String authorizationCode;
     private String clientId;
+    private String clientDescription;
     private String userId;
     private long expiresIn;
     
@@ -49,15 +50,6 @@ public class OOBAuthorizationResponse {
         this.userId = userId;
     }
 
-    @Deprecated
-    public long getLifetime() {
-        return expiresIn;
-    }
-    @Deprecated
-    public void setLifetime(long lifetime) {
-        this.expiresIn = lifetime;
-    }
-    
     public long getExpiresIn() {
         return expiresIn;
     }
@@ -65,5 +57,13 @@ public class OOBAuthorizationResponse {
     public void setExpiresIn(long lifetime) {
         this.expiresIn = lifetime;
     }
+
+    public String getClientDescription() {
+        return clientDescription;
+    }
+
+    public void setClientDescription(String clientDescription) {
+        this.clientDescription = clientDescription;
+    }
     
 }

http://git-wip-us.apache.org/repos/asf/cxf/blob/ed042118/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/AuthorizationCodeGrantService.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/AuthorizationCodeGrantService.java
b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/AuthorizationCodeGrantService.java
index dbb2663..b782880 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/AuthorizationCodeGrantService.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/AuthorizationCodeGrantService.java
@@ -128,6 +128,7 @@ public class AuthorizationCodeGrantService extends RedirectionBasedGrantService
         if (state.getRedirectUri() == null) {
             OOBAuthorizationResponse oobResponse = new OOBAuthorizationResponse();
             oobResponse.setClientId(client.getClientId());
+            oobResponse.setClientDescription(client.getApplicationDescription());
             oobResponse.setAuthorizationCode(grant.getCode());
             oobResponse.setUserId(userSubject.getLogin());
             oobResponse.setExpiresIn(grant.getExpiresIn());


Mime
View raw message