Reputation: 301
I'm using the keycloak client adapter as an SP for to use SAML SSO with an IDP. The SP is expecting the ACS url to be The problem is that the client that connects to the SP is behind a proxy , and all the HTTP requests turn to HTTPS, and it is blocked on the SP level with this exception :
org.keycloak.adapters.saml.profile.AbstractSamlAuthenticationHandler.handleSamlResponse Request URI 'http://example.com/context/saml' does not match SAML request destination 'https://example.com/context/saml'
Is there any way to configure the SP to change its default ACS url expected to be in HTTPS ?
Upvotes: 0
Views: 696
Reputation: 301
I fixed this issue by configuring tomcat server.xml to accept HTTPS scheme from the proxy on the http port.
<Connector port="8080" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443"
proxyName="proxy.com"
proxyPort="443" scheme="https" />
Upvotes: 1