Skip to content

Workarounds Required to Support Microsoft Azure as Auth Server #862

@2underscores

Description

@2underscores

Support Azure for Enterprise Adoption

  • With MCP SDK, Azure AD cannot be used as the Authorisation Server (AS) as Azure:
    • Does not advertise PKCE in AS metadata
    • Uses scope param instead of RFC 8707's resource param
  • MCP SDK should support Azure as an AS, as Azure is extremely commonly used, particularly in enterprise.

PKCE Not Advertised

scope instead of resource

  • RFC 8707 - Resource Indicators for OAuth 2.0 is an optional extension to OAuth, that MCP has as mandatory.
  • It introduces the resource param that indicates which protected resource the client is requesting access to.
    • This is included in /authorize and /token endpoints, and in the JWT's aud claim.
  • Azure v2 endpoints do not implement RFC 8707. They implement a very similar scope parameter in place of the resource param
    • scope is a superset, and includes both the "resource" access is being requested to, and the actions ("scopes") to perform on it.
  • Azure AS will fail if resource is provided (i.e. It does not ignore/silently drop it)
  • To support Azure, conditional logic is needed to provide scope in place of resource with the required minor change to value.

Other Related Azure Issues

This commit has one implementation of the compatibility changes needed to support Azure as AS.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions