Skip to content
This repository was archived by the owner on Oct 18, 2025. It is now read-only.
This repository was archived by the owner on Oct 18, 2025. It is now read-only.

Resource Identifier Validation Enforces URL Semantics #67

@dacamposol

Description

@dacamposol

RFC 8707 and RFC 8693 introduce the resource indicator for OAuth 2.0, defined as a URI. Critically, RFC 8707 states:

The client SHOULD use the base URI of the API as the resource parameter value unless specific knowledge of the resource dictates otherwise.

Many Authorization Server implementations (correctly) interpret this as allowing the use of URNs to uniquely identify logical resources within an application scope. For example:

urn:<NAMESPACE>:identity:application:provider:name:<API_NAME>

This pattern is in production today.

However, the resource metadata validation (per the draft) enforces strict identity checks on the resource field that are only coherent if the resource identifier is a URL:

The resource value returned MUST be identical to the protected resource's resource identifier value into which the well-known URI path suffix was inserted to create the URL used to retrieve the metadata.
...
If the protected resource metadata was retrieved from a URL returned by the protected resource via the WWW-Authenticate resource_metadata parameter, then the resource value returned MUST be identical to the URL that the client used to make the request to the resource server.

These rules imply a strict one-to-one mapping between resource identifiers and metadata URLs, assuming that the resource is a dereferenceable HTTP(S) URL. This assumption breaks when URNs or other non-resolvable identifiers are used, which is entirely valid per the original RFCs.

As a consequence, this breaks compatibility with existing deployments where:

  • Authorization Servers issue tokens based on URNs as resource values
  • Resource Servers use these URNs for authorization decisions
  • No direct HTTP URL representation of the resource exists or is meaningful

Such deployments cannot expose metadata under a .well-known location derived from a URL, because no such URL exists for the resource identifier.

RFC 8693 explicitly supports abstract (non-dereferenceable) resource identifiers:

A URI that indicates the target service or resource where the client intends to use the requested security token. [...] In many cases, a client will not have knowledge of the logical organization of the systems with which it interacts and will only know a URI of the service where it intends to use the token.

This explicitly anticipates situations where the client uses opaque or abstract URIs (like URNs) to indicate the target resource.

Request

Please clarify whether the intent is to mandate resolvable URL-based resource identifiers across the ecosystem, or whether the spec should remain compatible with URN-based deployments as allowed by RFC 8693 and RFC 8707.

If URL-based identity is mandatory, this constitutes a breaking change that invalidates a class of compliant implementations. If not, the metadata validation rules should be revised to support non-URL resource identifiers (e.g., by decoupling the identifier from the retrieval URL, or by providing an explicit mapping).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions