[java-identity-provider] branch main updated: Bit of minor cleanup.
Scott Cantor
cantor.2 at osu.edu
Tue Jul 23 15:22:25 UTC 2024
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch main
in repository java-identity-provider.
View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=2947be80e3c9f1f5c03f93d775bb74af66ce3af4
The following commit(s) were added to refs/heads/main by this push:
new 2947be80e Bit of minor cleanup.
2947be80e is described below
commit 2947be80e3c9f1f5c03f93d775bb74af66ce3af4
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue Jul 23 11:22:22 2024 -0400
Bit of minor cleanup.
---
.../impl/PopulateBindingAndEndpointContexts.java | 33 ++++++++--------------
1 file changed, 11 insertions(+), 22 deletions(-)
diff --git a/idp-saml-impl/src/main/java/net/shibboleth/idp/saml/profile/impl/PopulateBindingAndEndpointContexts.java b/idp-saml-impl/src/main/java/net/shibboleth/idp/saml/profile/impl/PopulateBindingAndEndpointContexts.java
index 3bf5ff3fe..129e42c2f 100644
--- a/idp-saml-impl/src/main/java/net/shibboleth/idp/saml/profile/impl/PopulateBindingAndEndpointContexts.java
+++ b/idp-saml-impl/src/main/java/net/shibboleth/idp/saml/profile/impl/PopulateBindingAndEndpointContexts.java
@@ -52,7 +52,6 @@ import org.opensaml.saml.saml2.metadata.RoleDescriptor;
import org.slf4j.Logger;
import net.shibboleth.idp.profile.AbstractProfileAction;
-import net.shibboleth.idp.saml.profile.config.SAMLProfileConfiguration;
import net.shibboleth.idp.saml.saml2.profile.config.BrowserSSOProfileConfiguration;
import net.shibboleth.profile.context.RelyingPartyContext;
import net.shibboleth.saml.profile.config.SAMLArtifactAwareProfileConfiguration;
@@ -346,25 +345,16 @@ public class PopulateBindingAndEndpointContexts extends AbstractProfileAction {
if (rpContext != null) {
relyingPartyId = rpContext.getRelyingPartyId();
verified = rpContext.isVerified();
- if (rpContext.getProfileConfig() != null
- && rpContext.getProfileConfig() instanceof SAMLProfileConfiguration) {
- final SAMLProfileConfiguration profileConfiguration =
- (SAMLProfileConfiguration) rpContext.getProfileConfig();
- if (profileConfiguration instanceof SAMLArtifactAwareProfileConfiguration) {
- artifactConfiguration =
- ((SAMLArtifactAwareProfileConfiguration) profileConfiguration).getArtifactConfiguration(
- profileRequestContext);
- }
- if (profileConfiguration instanceof BrowserSSOProfileConfiguration) {
- final BrowserSSOProfileConfiguration ssoConfig =
- (BrowserSSOProfileConfiguration) profileConfiguration;
- skipValidationSinceSigned =
- inboundMessage instanceof AuthnRequest
- && ssoConfig.isSkipEndpointValidationWhenSigned(profileRequestContext)
- && !ssoConfig.isIgnoreRequestSignatures(profileRequestContext)
- && SAMLBindingSupport.isMessageSigned(
- Constraint.isNotNull(imc, "No Inboud Message Context"));
- }
+ if (rpContext.getProfileConfig() instanceof SAMLArtifactAwareProfileConfiguration artpc) {
+ artifactConfiguration = artpc.getArtifactConfiguration(profileRequestContext);
+ }
+ if (rpContext.getProfileConfig() instanceof BrowserSSOProfileConfiguration ssoConfig) {
+ skipValidationSinceSigned =
+ inboundMessage instanceof AuthnRequest
+ && ssoConfig.isSkipEndpointValidationWhenSigned(profileRequestContext)
+ && !ssoConfig.isIgnoreRequestSignatures(profileRequestContext)
+ && SAMLBindingSupport.isMessageSigned(
+ Constraint.isNotNull(imc, "No Inboud Message Context"));
}
}
@@ -384,7 +374,6 @@ public class PopulateBindingAndEndpointContexts extends AbstractProfileAction {
return true;
}
-//CheckStyle: ReturnCount OFF
/** {@inheritDoc} */
@Override protected void doExecute(@Nonnull final ProfileRequestContext profileRequestContext) {
@@ -498,7 +487,7 @@ public class PopulateBindingAndEndpointContexts extends AbstractProfileAction {
}
}
}
-// Checkstyle: CyclomaticComplexity|MethodLength|ReturnCount ON
+// Checkstyle: CyclomaticComplexity|MethodLength ON
/**
* Check for an inbound request binding that is synchronous and handle appropriately.
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list