feat: add pre-registration conformance test (#120)
* feat: add pre-registration conformance test Add conformance test for OAuth pre-registration flow where the server does NOT support Dynamic Client Registration (DCR) and clients must use pre-configured static credentials. This addresses issue #34 (Client Registration Methods) - specifically the pre-registration section that was previously not covered. Changes: - Add disableDynamicRegistration option to createAuthServer helper - Add auth/pre-registration scenario with pre-registered client creds - Add MCP_PREREGISTRATION spec reference - Add context schema for pre-registration credentials - Add withOAuthRetryWithProvider helper for pre-configured providers - Add negative test client (auth-test-attempts-dcr.ts) that ignores pre-registered credentials and fails The scenario verifies that when a server does not advertise registration_endpoint in its OAuth metadata, compliant clients use pre-registered credentials passed via context instead of attempting DCR. Closes #34 * fix: add redirect_uris to saveClientInformation call * chore: remove unused WithOAuthRetryOptions interface
This commit is contained in:
parent
5dca74be9a
commit
245e44e882
1 changed files with 304 additions and 4 deletions
|
|
@ -21,6 +21,7 @@ import {
|
|||
ClientCredentialsJwtScenario,
|
||||
ClientCredentialsBasicScenario
|
||||
} from './client-credentials';
|
||||
import { PreRegistrationScenario } from './pre-registration';
|
||||
|
||||
// Auth scenarios (required for tier 1)
|
||||
export const authScenariosList: Scenario[] = [
|
||||
|
|
@ -35,7 +36,8 @@ export const authScenariosList: Scenario[] = [
|
|||
new ScopeRetryLimitScenario(),
|
||||
new ClientSecretBasicAuthScenario(),
|
||||
new ClientSecretPostAuthScenario(),
|
||||
new PublicClientAuthScenario()
|
||||
new PublicClientAuthScenario(),
|
||||
new PreRegistrationScenario()
|
||||
];
|
||||
|
||||
// Extension scenarios (optional for tier 1 - protocol extensions)
|
||||
|
|
|
|||
Loading…
Reference in a new issue