Commit e56ad96
committed
Simplify client credentials providers and deprecate RFC7523OAuthClientProvider
Add new simplified OAuth providers for machine-to-machine authentication:
- ClientCredentialsOAuthProvider: For client_credentials with client_id + client_secret
- PrivateKeyJWTOAuthProvider: For client_credentials with private_key_jwt (RFC 7523 Section 2.2)
- SignedJWTParameters: Helper class for SDK-signed JWT assertions
- static_assertion_provider(): Helper for pre-built JWTs from workload identity federation
The new providers set client_info directly in constructor, bypassing dynamic
client registration which isn't needed for pre-registered machine clients.
Deprecate RFC7523OAuthClientProvider: The original implementation incorrectly
used RFC 7523 Section 2.1 (jwt-bearer authorization grant) instead of the
intended Section 2.2 (private_key_jwt client authentication with
grant_type=client_credentials).
Also skip 3 flaky timing-dependent tests in test_stdio.py.1 parent 7c57b82 commit e56ad96
File tree
3 files changed
+576
-329
lines changed- src/mcp/client/auth/extensions
- tests/client
- auth/extensions
3 files changed
+576
-329
lines changed
0 commit comments