Skip to content

clientId is HardCoded in FlurlExtensions.cs #72

Open
@anshumanchatterji

Description

@anshumanchatterji
                 var result = await url
                .AppendPathSegment($"/auth/realms/{realm}/protocol/openid-connect/token")
                .WithHeader("Content-Type", "application/x-www-form-urlencoded")
                .PostUrlEncodedAsync(new List<KeyValuePair<string, string>>
                {
                    new KeyValuePair<string, string>("grant_type", "client_credentials"),
                    new KeyValuePair<string, string>("client_secret", clientSecret),
                    new KeyValuePair<string, string>("client_id", "admin-cli")    // <-------------------- Hardcoded
                })
                .ReceiveJson().ConfigureAwait(false);

There should be an overload in the constructor of KeycloakClient where client_id could be passed. I could submit a PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions