Skip to content

Add per-provider enrich with userinfo endpoint setting#1445

Merged
julien-nc merged 3 commits into
nextcloud:mainfrom
s3n-w6i:feat/per_provider_enrich_userinfo2
May 29, 2026
Merged

Add per-provider enrich with userinfo endpoint setting#1445
julien-nc merged 3 commits into
nextcloud:mainfrom
s3n-w6i:feat/per_provider_enrich_userinfo2

Conversation

@s3n-w6i
Copy link
Copy Markdown
Contributor

@s3n-w6i s3n-w6i commented May 22, 2026

What

This change introduces a checkbox into the provider settings that allows enabling the existing enrich_login_id_token_with_userinfo option on a per-provider basis.
To be backwards compatible, if the global enrich_login_id_token_with_userinfo is set to true, the userinfo endpoint is still fetched for all providers, regardless of their per-provider setting.

Why

  • It depends on the provider whether the userinfo endpoint needs to be fetched, so a per-provider setting better represents that.
  • For people with a hosted Nextcloud offering like myself, there may not be an option to set the global configuration option.

Open questions

  • I have tested it successfully using a Keycloak instance. Are integration tests required?
  • Regarding migration: This is a new option enrichLoginIdTokenWithUserinfo on the provider's settings object. This does not require any database schema changes, right?

Signed-off-by: s3n-w6i <37022952+s3n-w6i@users.noreply.github.com>
Copy link
Copy Markdown
Member

@julien-nc julien-nc left a comment

Choose a reason for hiding this comment

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

Nice PR, thanks.

  • Backward compatibility 👍
  • No migration needed 👍 because the value is stored in app config as a new row with the key provider-N-enrichLoginIdTokenWithUserinfo for each provider

Comment thread l10n/en_GB.json
Signed-off-by: s3n-w6i <37022952+s3n-w6i@users.noreply.github.com>
@julien-nc julien-nc self-requested a review May 29, 2026 10:05
testGetProvidersWithSettings: Since all boolean options are set to true by default, also set enrichLoginIdTokenWithUserinfo to true

testSetSettings: Add missing enrichLoginIdTokenWithUserinfo field

Signed-off-by: s3n-w6i <37022952+s3n-w6i@users.noreply.github.com>
@julien-nc julien-nc merged commit 7294acf into nextcloud:main May 29, 2026
51 checks passed
@s3n-w6i s3n-w6i deleted the feat/per_provider_enrich_userinfo2 branch May 29, 2026 11:59
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 6, 2026

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

(If you believe you should not receive this message, you can add yourself to the blocklist.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants