Skip to content

Error Response is not OAuth2 compliant #958

Open
@thuethe

Description

@thuethe

On Issuing an Access Token the OAuth 2.0 Server produces an error response like:

{
    "error": "invalid_client",
    "message": "Client authentication failed"
}

with optional hint in some cases.

Specs compliant would be an error response like:

{
    "error": "invalid_client",
    "error_description": "Client authentication failed",
    "error_uri": "..."
}

error_uri and error_description are optional.

From the specs (https://tools.ietf.org/html/rfc6749#section-5.2):

The authorization server responds with an HTTP 400 (Bad Request)
status code (unless specified otherwise) and includes the following
parameters with the response:
error
REQUIRED. [...]
error_description
OPTIONAL. Human-readable ASCII [USASCII] text providing
additional information, used to assist the client developer in
understanding the error that occurred.
Values for the "error_description" parameter MUST NOT include
characters outside the set %x20-21 / %x23-5B / %x5D-7E.
error_uri
OPTIONAL. A URI identifying a human-readable web page with
information about the error, used to provide the client
developer with additional information about the error.
Values for the "error_uri" parameter MUST conform to the
URI-reference syntax and thus MUST NOT include characters
outside the set %x21 / %x23-5B / %x5D-7E.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions