dxbjavid commented on code in PR #3281:
URL: https://github.com/apache/cxf/pull/3281#discussion_r3663038893
##########
rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/SAMLSSOResponseValidator.java:
##########
@@ -169,8 +169,8 @@ private void
validateIssuer(org.opensaml.saml.saml2.core.Issuer issuer) throws W
return;
}
- // Issuer value must match (be contained in) Issuer IDP
- if (enforceKnownIssuer && (issuer.getValue() == null ||
!issuerIDP.startsWith(issuer.getValue()))) {
+ // Issuer value must match the configured Issuer IDP
+ if (enforceKnownIssuer && !issuerIDP.equals(issuer.getValue())) {
Review Comment:
that works for me, thanks. i have pushed your matchesKnownIssuer version
pretty much as written, so a same-origin prefix like the entityID being a
prefix of the SSO endpoint still passes, but arbitrary short prefixes on a
different scheme/host/port no longer do. i also added an
enforceStrictIssuerMatch flag (default false to keep the current behaviour) for
deployments that want exact matching only. the tests now cover a rejected short
prefix, an accepted same-origin prefix, and the strict case rejecting the
prefix.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]