Skip to content

register_client drops client_secret_expires_at from the registration response #1416

Open

Description

@FalkWoldmann

AuthorizationManager::register_client parses the whole registration response, but only returns an OAuthClientConfig, which has no client_secret_expires_at. So a client that stores its registration can't tell when the secret lapses, even though RFC 7591 requires the field whenever a secret is issued. In maki we now register a new client on every login instead of reusing one that has a secret, since it might be dead.

Could OAuthClientConfig keep the expiry, or register_client return the full ClientRegistrationResponse? Happy to do a PR for either

Activity

  1. added
    bug
    P2
    T-security
    ready for work
    on Oct 30, 2026
  2. github-actions commented on Oct 30, 2026

    @github-actions
    Contributor

    @gocamille is on triage rotation this week and is the reviewer for this one.

    Codex labeled this bug / P2 (T-security). Please confirm or correct those labels.

    Automated triage. Labels are a first pass and the assigned maintainer has the final say.

  3. added a commit that references this issue on Nov 11, 2026
    827c4df
  4. added a commit that references this issue on Nov 20, 2026
    b21cdc7
  5. marcus-beauregard commented on Nov 20, 2026

    @marcus-beauregard

    Took the first option in #1478 — OAuthClientConfig keeps client_secret_expires_at (seconds since epoch) instead of register_client returning the full response.

    Reason: both OAuthClientConfig and ClientRegistrationResponse are #[non_exhaustive], so the added field is additive per VERSIONING.md, while changing register_client's return type is a public signature change. 0 (never expires) and a missing field both land as None, matching the existing empty-string client_secret rule, so Some is always a real deadline to schedule against.

    Tests: cargo test -p rmcp --lib --features auth — 593 passed; the new test fails on left: None, right: Some(1767225600) when the mapping is reverted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P2T-securitybugready for work

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions