modelcontextprotocol / modelcontextprotocol/php-sdk

[Client] Support token_endpoint_auth_method: client_secret_basic, client_secret_post, none

オープン
#321 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

auth Client enhancement improves spec compliance
主要言語
PHP
スター
1.6k
フォーク
173
平均マージ
2日 49分
マージ済み PR(30日)
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 Basic Authorization: Basic base64(client_id:client_secret)
  • client_secret_post → form-encoded client_id + client_secret body params
  • none → public client; only client_id in 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

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. 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 をユニットテストと併用します。3 つすべての戦略がカバーされ、3 つのベースラインシナリオがパスすれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
php
領域
authentication
issue の種類
機能追加
難易度
4/5
見積もり時間
3〜5日
活発さ
静か
明瞭さ
おおむね明確
初心者へのやさしさ
55/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。