Skip to content
Snippets Groups Projects
Commit 0eadf33a authored by Rohith Jayawardene's avatar Rohith Jayawardene Committed by GitHub
Browse files

Revocation url (#254)

* Recovation URL

- stopping the logout handler from panicing when the revocation url has not been set. Google OpenID appears to stray from
  the OpenID spec and use's another name of the endpoint. None the less we should check beforehand

* - updating the CHANGELOG to reflect the changes
parent ffe2fc44
No related branches found
No related tags found
No related merge requests found
......@@ -10,6 +10,7 @@ FIXES:
* fixed a number of linting errors highlighted by gometalinter [#PR209](https://github.com/gambol99/keycloak-proxy/pull/209)
* added docker image instructions to the readme [#PR204](https://github.com/gambol99/keycloak-proxy/pull/204)
* added unit tests for the debug handlers [#PR223](https://github.com/gambol99/keycloak-proxy/pull/223)
* fixing the logout handler panic when revocation url is not set [#PR254](https://github.com/gambol99/keycloak-proxy/pull/254)
FEATURES
* changed the routing engine from gin to echo
......
......@@ -295,7 +295,13 @@ func (r *oauthProxy) logoutHandler(w http.ResponseWriter, req *http.Request) {
}()
}
revocationURL := defaultTo(r.config.RevocationEndpoint, r.idp.EndSessionEndpoint.String())
// set the default revocation url
revokeDefault := ""
if r.idp.EndSessionEndpoint != nil {
revokeDefault = r.idp.EndSessionEndpoint.String()
}
revocationURL := defaultTo(r.config.RevocationEndpoint, revokeDefault)
// step: do we have a revocation endpoint?
if revocationURL != "" {
client, err := r.client.OAuthClient()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment