Skip to content

Authorization URL validations required by the OAuth 2.1 specification not implemented #3856

Open

Description

@padraig-ohiceadha

Initial Checks

Release line

2.x (current stable)

Description

Similar to the existing handling of resource urls OAuth 2.1 requires that URL fragments not be included in the authorization url and that it not contain any of the params used by the authorization request. Neither of these are currently checked for in _perform_authorization_code_grant
The specification also requires that any existing query params are retained, which are not today ( there is an issue open of this particular part of the issue - #2776 ).

For the OAuth 2.1 specification requirements see section 3.1 of https://datatracker.ietf.org/doc/html/draft-ietf-oauth-v2-1#name-authorization-endpoint

Example Code

Python & MCP Python SDK

Python 3.11.9
2.3.1.dev20

Activity

  1. added
    bug
    v1
    v2
    on Nov 13, 2026
  2. media-ctrl commented on Nov 14, 2026

    @media-ctrl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugv1v2

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions