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 an option to hint to OAuth2 view handlers if single page apps can be supported
Date Mon, 03 Apr 2017 16:17:56 GMT
Repository: cxf
Updated Branches:
  refs/heads/master c704db9f6 -> 7476fc331


Adding an option to hint to OAuth2 view handlers if single page apps can be supported


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

Branch: refs/heads/master
Commit: 7476fc331f00a01851b5fbb66758818bef8ba2c4
Parents: c704db9
Author: Sergey Beryozkin <sberyozkin@gmail.com>
Authored: Mon Apr 3 17:17:40 2017 +0100
Committer: Sergey Beryozkin <sberyozkin@gmail.com>
Committed: Mon Apr 3 17:17:40 2017 +0100

----------------------------------------------------------------------
 .../rs/security/oauth2/common/OAuthAuthorizationData.java | 10 ++++++++++
 .../oauth2/services/RedirectionBasedGrantService.java     |  5 +++++
 2 files changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/7476fc33/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthAuthorizationData.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthAuthorizationData.java
b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthAuthorizationData.java
index 7a48504..01aeded 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthAuthorizationData.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthAuthorizationData.java
@@ -55,6 +55,7 @@ public class OAuthAuthorizationData extends OAuthRedirectionState implements
Ser
     private List<OAuthPermission> alreadyAuthorizedPermissions;
     private boolean hidePreauthorizedScopesInForm;
     private boolean applicationRegisteredDynamically;
+    private boolean supportSinglePageApplications;
 
     public OAuthAuthorizationData() {
     }
@@ -266,4 +267,13 @@ public class OAuthAuthorizationData extends OAuthRedirectionState implements
Ser
         this.applicationRegisteredDynamically = applicationRegisteredDynamically;
     }
 
+    public boolean isSupportSinglePageApplications() {
+        return supportSinglePageApplications;
+    }
+
+    public void setSupportSinglePageApplications(boolean supportSinglePageApplications) {
+        this.supportSinglePageApplications = supportSinglePageApplications;
+    }
+
+    
 }

http://git-wip-us.apache.org/repos/asf/cxf/blob/7476fc33/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/RedirectionBasedGrantService.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/RedirectionBasedGrantService.java
b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/RedirectionBasedGrantService.java
index ca4b800..6798323 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/RedirectionBasedGrantService.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/services/RedirectionBasedGrantService.java
@@ -71,6 +71,7 @@ public abstract class RedirectionBasedGrantService extends AbstractOAuthService
     private boolean hidePreauthorizedScopesInForm;
     private AuthorizationRequestFilter authorizationFilter;
     private List<String> scopesRequiringNoConsent;
+    private boolean supportSinglePageApplications = true;
 
     protected RedirectionBasedGrantService(String supportedResponseType,
                                            String supportedGrantType) {
@@ -288,6 +289,7 @@ public abstract class RedirectionBasedGrantService extends AbstractOAuthService
             Map<String, String> extraProperties = client.getProperties();
             secData.setExtraApplicationProperties(extraProperties);
             secData.setApplicationRegisteredDynamically(client.isRegisteredDynamically());
+            secData.setSupportSinglePageApplications(supportSinglePageApplications);
             String replyTo = getMessageContext().getUriInfo()
                 .getAbsolutePathBuilder().path("decision").build().toString();
             secData.setReplyTo(replyTo);
@@ -578,4 +580,7 @@ public abstract class RedirectionBasedGrantService extends AbstractOAuthService
     public void setScopesRequiringNoConsent(List<String> scopesRequiringNoConsent)
{
         this.scopesRequiringNoConsent = scopesRequiringNoConsent;
     }
+    public void setSupportSinglePageApplications(boolean supportSinglePageApplications) {
+        this.supportSinglePageApplications = supportSinglePageApplications;
+    }
 }


Mime
View raw message