Skip to content
This repository has been archived by the owner on Nov 16, 2022. It is now read-only.

Setting "false" to some boolean fields for an existing client does not actually change the client on keycloak #454

Closed
christianviana opened this issue Jan 20, 2022 · 1 comment
Assignees
Labels

Comments

@christianviana
Copy link

christianviana commented Jan 20, 2022

Describe the bug

I am editing an existing KeycloakClient in an attempt update some boolean fields.
However, if the fields are currently set to "true", setting them to "false" fails to actually update the client in Keycloak.

Not all boolean fields were tested, some worked, but some didn't.

Fields that didn't get updated:

  • enabled
  • consentRequired
  • serviceAccountsEnabled

Fields that got updated:

  • standardFlowEnabled
  • implicitFlowEnabled
  • directAccessGrantsEnabled

Transition from enabled: false to enabled: true is working fine in all tested fields.

Version

16.1.0

Expected behavior

All the fields should be updated.

Actual behavior

Not all boolean fields were tested, some were updated, but some didn't.

Fields that didn't get updated:

  • enabled
  • consentRequired
  • serviceAccountsEnabled

Fields that got updated:

  • standardFlowEnabled
  • implicitFlowEnabled
  • directAccessGrantsEnabled

How to Reproduce?

  • Create a new "disabled" client
  • Open Keycloak and verify that the client is disabled
  • Update the client to enable it.
  • Open Keycloak and verify the client is enabled
  • Attempt to disable the Client
  • Open Keycloak and verify the client is not update to disabled

You can try these steps with the other reported fields:

  • consentRequired
  • serviceAccountsEnabled

Anything else?

I found the issue #412, related to the "enabled" field. As I was not sure if these other fields would be treated there, I opened this issue, sorry if this is considered a duplicate.

@andreaTP
Copy link
Contributor

Hi @christianviana ,

thanks for reporting this issue, which stands valid.
As you mentioned it's already tracked in #412 and I'll close this one as duplicate, but thanks a lot for the reproduction steps!

The common pattern is that boolean flag are not reconciled correctly.

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

No branches or pull requests

2 participants