Client metadata support

From RedHatProductSecurity/prodsec-skills · View interactive version

Client metadata support is an AI agent skill from the GitHub repository RedHatProductSecurity/prodsec-skills. Support OAuth Client ID Metadata Documents in authorization servers. Use when building or reviewing authorization server client validation and registration mechanisms for MCP ecosystems.

How to use this skill

Skill file

OAuth Client ID Metadata Document Support in Authorization Servers

Security Recommendation

Authorization servers SHOULD support OAuth Client ID Metadata Documents. This mechanism allows clients (including MCP clients) to present their identity and configuration without requiring pre-registration, by hosting a metadata document at their client_id URL.

How It Works

  1. Client presents a client_id that is an HTTPS URL (e.g., https://mcp-client.example.com/client-metadata)
  2. Authorization server fetches the metadata document from that URL
  3. Authorization server validates the client's configuration from the document
  4. Authorization server uses the metadata for the OAuth flow

Validation Rules

When fetching and processing client metadata documents, the authorization server MUST:

| Rule | Details |

|---|---|

| Fetch over HTTPS | Only retrieve metadata from HTTPS URLs |

| Verify client_id match | The client_id in the document must match the URL it was fetched from |

| Validate redirect_uris | Ensure redirect URIs are valid and use HTTPS |

| Check grant types | Only allow grant types the server supports |

| Apply security policies | Enforce server-side policies on client configurations |

Implementation Checklist

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.