/** * Resolve the SAML entity ID from a SAML 1 AttributeQuery. * * @param query the query * * @return the entity ID, or null if it could not be resolved */ @Nullable protected String processSaml1AttributeQuery(@Nonnull final AttributeQuery query) { if (getUseSAML1QueryResourceAsEntityId()) { log.debug("Attempting to extract entity ID from SAML 1 AttributeQuery Resource attribute"); final String resource = StringSupport.trimOrNull(query.getResource()); if (resource != null) { log.debug("Extracted entity ID from SAML 1.x AttributeQuery: {}", resource); return resource; } } return null; }
/** * Resolve the SAML entityID from a SAML 1 AuthorizationDecisionQuery. * * @param query the query * * @return the entity ID, or null if it could not be resolved */ @Nullable protected String processSaml1AuthorizationDecisionQuery(@Nonnull final AuthorizationDecisionQuery query) { if (getUseSAML1QueryResourceAsEntityId()) { log.debug("Attempting to extract entity ID from SAML 1 AuthorizationDecisionQuery Resource attribute"); final String resource = StringSupport.trimOrNull(query.getResource()); if (resource != null) { log.debug("Extracted entity ID from SAML 1.x AuthorizationDecisionQuery: {}", resource); return resource; } } return null; }