OAuth 2.0 Protected Resource Metadata

Demo · format-valid IANA · permanent

/.well-known/oauth-protected-resource

Standard: RFC 9728

The 2024 counterpart to RFC 8414: let a protected resource advertise which authorization servers may issue tokens for it.

What it is

RFC 9728 publishes metadata for the resource side of OAuth: which authorization servers are permitted to issue access tokens for this resource, so resource servers can reject tokens from unknown ASes.

The threat it addresses

Resource servers used to accept tokens from any AS that happened to sign them, or had to hardcode AS lists. Metadata makes the authorized-AS set explicit and discoverable, closing the door on tokens minted by rogue servers.

How it works

  • The resource serves /.well-known/oauth-protected-resource with its own URI and the list of authorization_servers it trusts.
  • Clients and resource servers use it to bind tokens to the right AS (and the right resource indicator).
  • This demo advertises the demo issuer on this origin.

Try it

Live demo

Format-valid demo metadata (RFC 9728 is brand new — this is one of the first public examples)

Content-Type: application/json; charset=utf-8
{
  "resource": "https://well-known.page/demo/protected-resource",
  "authorization_servers": [
    "https://well-known.page"
  ],
  "resource_metadata": {
    "resource": "https://well-known.page/demo/protected-resource",
    "authorization_servers": [
      "https://well-known.page"
    ]
  },
  "_demo_note": "RFC 9728 protected resource metadata for well-known.page (demo resource)."
}