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

add extra_config for openid clients to handle custom attributes (#387) #579

Merged
merged 1 commit into from
Sep 3, 2021

Conversation

olivierboudet
Copy link
Contributor

@olivierboudet olivierboudet commented Aug 19, 2021

Hello @mrparkers ,

As the PR #389 seems blocked since several months and because I need to manage custom attributes on openid clients, I tried to make a new PR. This new PR handles only a new extra_config field on keycloak_openid_client.

However I have a question : as Keycloak recently added 2 new attributes with default values (backchannel.logout.revoke.offline.tokens=false and backchannel.logout.session.required=true, as described in #568), how should we handle these attributes ? I modified all the tests to add these new attributes in data, is this correct waiting for an official support for these fields ?
The advantage on this solution is that it allows to set all new attributes added by Keycloak before an official support in the provider.
The drawback is it become mandatory to set this extra_config when using KC >= 12.x with a provider which do not support this fields natively.

extra_config = {
  "backchannel.logout.revoke.offline.tokens" = "false"
  "backchannel.logout.session.required"      = "true"
}

@olivierboudet olivierboudet marked this pull request as draft August 19, 2021 21:20
@olivierboudet olivierboudet marked this pull request as ready for review August 19, 2021 21:59
Copy link
Contributor

@mrparkers mrparkers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @olivierboudet, thanks for the PR. I think supporting extra_config is fine for this resource.

As far as the backchannel attributes goes, I went ahead and opened #583 to support these as top level attributes. So you can remove the changes that adds these attributes through extra_config.

docs/resources/openid_client.md Outdated Show resolved Hide resolved
provider/resource_keycloak_openid_client.go Outdated Show resolved Hide resolved
@olivierboudet olivierboudet force-pushed the master branch 3 times, most recently from 40c3d18 to 078bac5 Compare August 31, 2021 08:07
Copy link
Contributor

@mrparkers mrparkers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, LGTM 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants