Skip to content

token endpoint should not require client secret in request #35

@tiziano88

Description

@tiziano88

Currently the server requires that the client sends back its id and secret to the server when exchanging an authorization code for an access token:

But the OAuth2 RFC does not require this: https://tools.ietf.org/html/rfc6749#section-4.1.3 i.e. the code itself should be enough to uniquely identify the client (passing the client_id parameter is allowed, though optional).

This means that currently this server implementation does not correctly work with the standard Go oauth2 library, and I guess many others.

I think a fix could be to maintain a map from authorization codes to clients, and use it to look up the client instead of expecting id and secret to be provided in the request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions