Interface McpClientRegistrationStore

All Known Implementing Classes:
InMemoryMcpClientRegistrationStore

SEP-2352 optional persistence SPI for Dynamic-Client-Registration / pre-registered credentials, keyed by the authorization server's issuer identifier.

Persistence is SHOULD-level: an MCP client that performs on-demand DCR on every connection with no store is fully compliant. When a store is used, the SEP-2352 keying MUST bites — credentials MUST be associated with the specific AS that issued them, and separate registration state MUST be kept per AS (InMemoryMcpClientRegistrationStore keys by issuer.toString()). McpClientRegistrationManager consults a store (if present) to reuse an issuer-keyed entry and to drive re-registration on AS migration.

Security

A store holds clientSecret / registration-access-token material (via McpClientRegistration). The default InMemoryMcpClientRegistrationStore is process-scoped; a durable implementation a caller supplies is responsible for at-rest protection and MUST NOT log credential material.

Since:
10.0.0
  • Method Summary

    Modifier and Type
    Method
    Description
    find(URI issuer)
    Returns the registration stored for the given AS issuer, if any.
    void
    put(URI issuer, McpClientRegistration registration)
    Stores (or replaces) the registration for the given AS issuer.
    void
    remove(URI issuer)
    Removes any registration stored for the given AS issuer.
  • Method Details

    • find

      Returns the registration stored for the given AS issuer, if any.
      Parameters:
      issuer - The authorization server issuer identifier. Must not be null.
      Returns:
      The stored registration, or Optional.empty() if none is stored for that issuer.
    • put

      void put(URI issuer, McpClientRegistration registration)
      Stores (or replaces) the registration for the given AS issuer.
      Parameters:
      issuer - The authorization server issuer identifier. Must not be null.
      registration - The registration to store. Must not be null.
    • remove

      void remove(URI issuer)
      Removes any registration stored for the given AS issuer.
      Parameters:
      issuer - The authorization server issuer identifier. Must not be null.