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

acquire fn public in admin token retriever #120

Merged
merged 1 commit into from
Jun 18, 2024
Merged

Conversation

ovnicraft
Copy link
Contributor

@ovnicraft ovnicraft commented Jun 16, 2024

We need to get the admin token for service accounts.

as developer i would like to do:

let retriever = KeycloakServiceAccountAdminTokenRetriever::create(
    client_id,
    client_secret,
    realm,
    client,
};
let admin_token = retriever.acquire(&url).await;

We need to get the admin token for service accounts.
@kilork
Copy link
Owner

kilork commented Jun 18, 2024

I think authorization was never deeply thought in the crate to avoid to much complexity, simplicity here is basically to force users to think about how to do it for their case with minimal example.

If just access_token field is not enough and you really need the whole token, we can of course make it public. @ovnicraft Please comment before the weekend, as I plan to do a release for version 25 of keycloak this week.

@ovnicraft
Copy link
Contributor Author

Make it public its good enough to use a service account and get token, please make it public.

Good to know to get it on next release.

@kilork
Copy link
Owner

kilork commented Jun 18, 2024

Okay, also other supplier has acquire method public already, means, this makes this consistent.

@kilork kilork merged commit 732748f into kilork:master Jun 18, 2024
1 check passed
@kilork kilork added this to the 25.0.0 milestone Jun 19, 2024
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