Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to add query parameters in the log out URL #600

Open
cedricremond opened this issue Nov 4, 2020 · 0 comments
Open

Allow to add query parameters in the log out URL #600

cedricremond opened this issue Nov 4, 2020 · 0 comments
Labels
bug Something isn't working enhancement New feature or request triaged

Comments

@cedricremond
Copy link

cedricremond commented Nov 4, 2020

The plugin automatically adds some query parameters to the log out URL, but if query parameters are present in the log out URL provided in kibana.yml (opendistro_security.openid.logout_url) they are not taken into account.

The result is that the URL generated by the plugin is malformed.
For example, if I set my logout URL like this: https://mydomain.com?foo=bar, the plugin will generate this URL: https://mydomain.com?foo=bar?post_logout_redirect_uri=...&id_token_hint=....

The need to add custom query parameters can come from authentication platforms that doesn't follow the OpenID specifications.
For example Auth0 asks for the redirect URL to be under the returnTo key rather than post_logout_redirect_uri.

Query parameters that are defined in the configuration should be parsed and added to the final URL generated by the plugin.

EDIT: the URL generation happens here: https://github.com/opendistro-for-elasticsearch/security-kibana-plugin/blob/5a48aad200fa274b727140a7391f304e7f7a625f/server/auth/types/openid/routes.ts#L184-L191

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request triaged
Projects
None yet
Development

No branches or pull requests

4 participants