Client Discovery / Automatic Registration in OAuth2/OIDC
Tobias Looker, Mike Jones and Kristina Yasuda
The Problem
With conventional OAuth2 (and OpenID Connect which is built atop), a prerequisite for the client to interact with the AS/OP is that it must have a valid “client_id”. It is typical assigned by the AS/OP ahead of time.
While powerful, this model is unwieldy or unworkable for some use cases, such as:
The Problem
The Importance of the Client
Why don’t we just make the client anonymous in the protocol? E.g., no client_id
The challenge to solve is how the client can identify itself and provide information about itself without having to first register at the AS/OP
Why not Dynamic Client Registration?
As defined by RFC 7591 why not just use this?
In short there are unresolved challenges:
The Solution Approach
A model where instead of the client using an identifier assigned by the AS/OP, using one that is assigned and managed by the client itself, a URL.
aHdehcTiVjcKtoMgn
https://client.example.com
From
To
Prior Art / Precedents
In short, there is market validation for the pattern.
Automatic Registration Challenges
One Tried-and-True Approach
Federation Entity Statement
A Possible Starting Point
OAuth2 Client Discovery draft, which defines:
(Note that it’s not 100% compatible with Automatic Registration at present)
Example Discovery Request
Client ID: https://client.example.com
Metadata Location: https://client.example/com/.well-known/oauth-client
HTTP Get
Example Authorization Request
Client ID as encoded URL
New Parameter indicating the client ID is an encoded URL
Example Token Request
Client ID as URL
New Parameter indicating the client ID is a URL
A note on terminology difference?
Client discovery vs Automatic Registration
OAuth2 Client Discovery deliberately does not use language like “registration” because in the suggested model, the client is never registered with the AS/OP, instead discovered as required.
Another viewpoint is that “client registration” happens when the AS retrieves the client’s metadata
Further points of discussion