modelcontextprotocol / modelcontextprotocol/php-sdk
[Client] Support token_endpoint_auth_method: client_secret_basic, client_secret_post, none
未关闭
还没有人认领这个 Issue。
auth
Client
enhancement
improves spec compliance
- 主要语言
- PHP
- 星标
- 1.6k
- 派生
- 173
- 平均合并
- 2 天 49 分钟
- 30 天内合并 PR
- 23
描述
Context
Per RFC 6749 §2.3 (and AS metadata token_endpoint_auth_methods_supported), the client must send its credentials to the token endpoint using whichever method the AS advertises:
client_secret_basic→ HTTP BasicAuthorization: Basic base64(client_id:client_secret)client_secret_post→ form-encodedclient_id+client_secretbody paramsnone→ public client; onlyclient_idin body, no secret
Scope
- Strategy interface
TokenEndpointAuthInterface+ three implementations. - Auto-select implementation based on AS metadata's preferred method (intersect with what the client supports/has).
Conformance scenarios unblocked
auth/token-endpoint-auth-basic, auth/token-endpoint-auth-post, auth/token-endpoint-auth-none.
Dependencies
Blocked by: #318, #319.
Acceptance
- Unit tests per strategy.
- Conformance: 3 baseline scenarios pass.
cc @soyuka
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
先检查 TokenEndpointAuthInterface 的范围以及依赖项 #318 和 #319 中的工作,然后跟踪 AS 元数据如何公开 token_endpoint_auth_methods_supported。将一致性场景 auth/token-endpoint-auth-basic、auth/token-endpoint-auth-post 和 auth/token-endpoint-auth-none 与单元测试结合使用;当三种策略都得到覆盖且三个基线场景都通过时,即表示完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- php
- 领域
- authentication
- Issue 类型
- 功能
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 冷清
- 描述清晰度
- 基本清楚
- 新手友好度
- 55/100