Skip to content

Consent cannot be skipped for public clients using code response type #459

@kmohrf

Description

@kmohrf

Hey,

#222 already touched on this but was closed. I don’t think that the issue is actually resolved.

This code path controls the per-client require-consent setting:

if not authorize.client.require_consent and (
    authorize.is_client_allowed_to_skip_consent()
    and "consent" not in authorize.params["prompt"]
):
    return redirect(authorize.create_response_uri())

So if my client doesn’t require consent it’s still going to enter authorize.is_client_allowed_to_skip_consent, which will only return True if the client is either confidential or is using one of id_token or id_token token as response types. So a public client using the code response type will always trigger consent even if require_consent is disabled for the client.

I could provide a pull request but I’m not sure why is_client_allowed_to_skip_consent would only allow skipping consent for the id_token and id_token token response types. Is there any reasoning behind this?

Thank you for your time and effort!

Cheers

Konrad

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