[java-idp-oidc] branch main updated: Move off deprecated method name.

Scott Cantor cantor.2 at osu.edu
Tue Jan 4 23:50:22 UTC 2022


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch main
in repository java-idp-oidc.

View the commit online:
http://git.shibboleth.net/view/?p=java-idp-oidc.git;a=commit;h=369d2d42d493c4c9b77dba0a7e85f7478d378ed9

The following commit(s) were added to refs/heads/main by this push:
     new 369d2d42 Move off deprecated method name.
369d2d42 is described below

commit 369d2d42d493c4c9b77dba0a7e85f7478d378ed9
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue Jan 4 18:50:20 2022 -0500

    Move off deprecated method name.
---
 .../plugin/oidc/op/profile/impl/InitializeSubjectContext.java | 11 +++++------
 ...onContextClassReferenceFromAuthzCodeToResponseContext.java |  6 +++---
 .../idp/plugin/oidc/op/profile/impl/ValidateAccessToken.java  |  2 +-
 3 files changed, 9 insertions(+), 10 deletions(-)

diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/InitializeSubjectContext.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/InitializeSubjectContext.java
index 56ffa9fb..5435d27e 100644
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/InitializeSubjectContext.java
+++ b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/InitializeSubjectContext.java
@@ -40,12 +40,11 @@ public class InitializeSubjectContext extends AbstractOIDCTokenResponseAction {
     @Override
     protected boolean doPreExecute(@Nonnull final ProfileRequestContext profileRequestContext) {
         if (!super.doPreExecute(profileRequestContext)) {
-            log.error("{} pre-execute failed", getLogPrefix());
             return false;
         }
         
-        if (getOidcResponseContext().getTokenClaimsSet() == null) {
-            log.error("{} user principal not resolved from token", getLogPrefix());
+        if (getOidcResponseContext().getAuthorizationGrantClaimsSet() == null) {
+            log.warn("{} user principal not resolved from prior authorization grant", getLogPrefix());
             ActionSupport.buildEvent(profileRequestContext, EventIds.INVALID_MESSAGE);
             return false;
         }
@@ -57,9 +56,9 @@ public class InitializeSubjectContext extends AbstractOIDCTokenResponseAction {
     @Override
     protected void doExecute(@Nonnull final ProfileRequestContext profileRequestContext) {
         final SubjectContext subCtx = profileRequestContext.getSubcontext(SubjectContext.class, true);
-        subCtx.setPrincipalName(getOidcResponseContext().getTokenClaimsSet().getPrincipal());
-        log.debug("{} Created subject context {} for user {}", getLogPrefix(), subCtx,
-                getOidcResponseContext().getTokenClaimsSet().getPrincipal());
+        subCtx.setPrincipalName(getOidcResponseContext().getAuthorizationGrantClaimsSet().getPrincipal());
+        log.debug("{} Created subject context for user {}", getLogPrefix(), subCtx,
+                subCtx.getPrincipalName());
     }
 
 }
\ No newline at end of file
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/SetAuthenticationContextClassReferenceFromAuthzCodeToResponseContext.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/SetAuthenticationContextClassReferenceFromAuthzCodeToResponseContext.java
index 20a99d38..404bce47 100644
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/SetAuthenticationContextClassReferenceFromAuthzCodeToResponseContext.java
+++ b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/SetAuthenticationContextClassReferenceFromAuthzCodeToResponseContext.java
@@ -48,8 +48,8 @@ public class SetAuthenticationContextClassReferenceFromAuthzCodeToResponseContex
             return false;
         }
         
-        if (getOidcResponseContext().getTokenClaimsSet() == null) {
-            log.error("{} No authz claims", getLogPrefix());
+        if (getOidcResponseContext().getAuthorizationGrantClaimsSet() == null) {
+            log.warn("{} No claims found from prior authorization grant", getLogPrefix());
             ActionSupport.buildEvent(profileRequestContext, EventIds.INVALID_PROFILE_CTX);
             return false;
         }
@@ -59,7 +59,7 @@ public class SetAuthenticationContextClassReferenceFromAuthzCodeToResponseContex
     /** {@inheritDoc} */
     @Override
     protected void doExecute(@Nonnull final ProfileRequestContext profileRequestContext) {
-        getOidcResponseContext().setAcr(getOidcResponseContext().getTokenClaimsSet().getACR());
+        getOidcResponseContext().setAcr(getOidcResponseContext().getAuthorizationGrantClaimsSet().getACR());
     }
 
 }
\ No newline at end of file
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/ValidateAccessToken.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/ValidateAccessToken.java
index c44dbfaa..1efff679 100644
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/ValidateAccessToken.java
+++ b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/plugin/oidc/op/profile/impl/ValidateAccessToken.java
@@ -108,7 +108,7 @@ public class ValidateAccessToken extends AbstractOIDCUserInfoValidationResponseA
             return;
         }
         log.debug("{} access token {} validated", getLogPrefix(), accessTokenClaimsSet.getID());
-        getOidcResponseContext().setTokenClaimsSet(accessTokenClaimsSet);
+        getOidcResponseContext().setAuthorizationGrantClaimsSet(accessTokenClaimsSet);
     }
 
 }
\ No newline at end of file

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list