OAuth 2.0 Bound Configuration LookupOraclephil.hunt@yahoo.comhttp://www.independentid.comMicrosofttonynad@microsoft.com
Security
OAuth Working GroupOAuthDiscoveryAuthorization ServerConfiguration InformationMetadataWebFingerJavaScript Object NotationJSONJSON Web TokenJWT
This specification defines a mechanism for the client of an OAuth 2.0 protected
resource service to obtain the configuration details of an OAuth 2.0
authorization server that is capable of authorizing access to a specific
resource service. The information includes the OAuth 2.0 component endpoint
location URIs and as well as authorization server capabilities.
This specification generalizes the configuration metadata format defined by
"OpenID Connect Discovery 1.0"
to support a wider set of OAuth 2.0 use cases.
This is intentionally parallel to the way that the
"OAuth 2.0 Dynamic Client Registration Protocol"
specification generalized the dynamic client registration mechanisms defined by
"OpenID Connect Dynamic Client Registration 1.0"
in a way that was compatible with it.
[[Editors note: This draft is intended as a replacement alternative
for consideration to draft-ietf-oauth-discovery-01 and as such it contains
the same metadata attribute definitions and registry requirements rather
than references the original draft.]]
This specification enables clients, having previously discovered
an OAuth 2.0 protected resource and an OAuth 2.0 Authorization service
(through other means such as an administrative process, a
configuration file, use of ".well-known" ), to discover
the OAuth 2.0 configuration metadata and to confirm the relationship
between the previously discovered authorization
server and the protected resource endpoints through the use of query mechanism.
This specification uses WebFinger to query
the authorization server configuration discovery to locate the assigned
authorization server (if any) for a specified resource endpoint URI and its
configuration properties as an authoritative set.
This process is described in .
The use WebFinger serves the following purposes:To allow service providers to have some flexibility in the relationship
and number of authorization servers able to issue access tokens for
use with OAuth 2.0 protected resources.Is the resource that the client is requesting authorization for supported
by the authorization server?To inform clients about improperly discovered endpoints
for valid resources. For example, that would enable an attacker to insert a proxy
for a "man-in-the-middle" attack.To bind together the resource service endpoint as part of a valid
set alone with the endpoints described in the OAuth configuration
metadata.
Once the authorization server has been identified,
this specification provides the configuration information that
is retrieved from a well-known location as a JSON document,
including its OAuth 2.0 endpoint locations and authorization server capabilities.
This process is described in .
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in RFC 2119.
All uses of JSON Web Signature (JWS)
and JSON Web Encryption (JWE)
data structures in this specification utilize
the JWS Compact Serialization or the JWE Compact Serialization;
the JWS JSON Serialization and the JWE JSON Serialization are not used.
This specification uses the terms "Access Token", "Authorization Code",
"Authorization Endpoint", "Authorization Grant", "Authorization Server",
"Client", "Client Authentication", "Client Identifier", "Client Secret",
"Grant Type", "Protected Resource", "Redirection URI", "Refresh Token",
"Resource Owner", "Resource Server", "Response Type", and "Token Endpoint"
defined by OAuth 2.0,
the terms "Claim Name", "Claim Value", and "JSON Web Token (JWT)"
defined by JSON Web Token (JWT),
and the term "Response Mode" defined by
OAuth 2.0 Multiple Response Type Encoding Practices.
This specification also defines the following terms:
Entity that is the target of a request in WebFinger.
Server where a WebFinger service is hosted.
Authorization server WebFinger discovery is a means of determining
the location of the authorization server's configuration information.
WebFinger discovery is RECOMMENDED; if a client knows the
authorization server's configuration information location through an out-of-band mechanism,
it can skip this step and proceed to .
WebFinger discovery uses the following information to make a
discovery request:
A REQUIRED URI that represents the actual resource URL the client intends to
use to access the protected resource. This URL may be for a specific
sub-set of data (e.g. associated with a resource owner), or it MAY
be the base URL for a set of protected resources accessible within
the scope of the client's anticipated access authorization. The URI
also be the base URL for a service when the end-user is a new user
and no specific user-owned resource is defined.
The server where the WebFinger service is hosted.
The URI identifying the type of service whose location is being requested.
OAuth 2.0 configuration discovery uses the following
rel value in
WebFinger:
Rel TypeURIOAuth 2.0 Configuration Informationoauth2
To start discovery of OAuth 2.0 configuration information,
the client first discover's the resource endpoint and the associated
OAuth URI through a mechanism defined by the resource service provider.
The parameter resource, whose value is the
protected resource's endpoint URL MUST be included.
The client then makes an HTTP GET request to the OAuth host's
WebFinger
endpoint using the URI as the resource parameter
value and the rel value
oauth2
to obtain the authorization server's configuration information location.
Upon receiving a request, the WebFinger service MAY match the specified
resource value through specific value matches
or the service MAY match a subset of the URI such as the host name and an
initial path. For example, if the client is using a URI to a specific subset
of resources, the subset can be ignored.
In the response, one or more matches MAY be returned in the
links array element. Each array element MUST contain
a rel attribute, an href
attribute, and a properties attribute.
The value of the href shall contain a value
equivalent to the OAuth "issuer" (see ). The
value of rel is oauth2.
The properties attribute contains the
authorization server configuration metadata (see )
that corresponds to the OAuth 2.0 server identified in the href
attribute. This information includes a set of claims about the authorization
server's configuration, including all necessary endpoints and public
key location information that contains a set of claims as its members
that are a subset of the metadata values defined in .
Other claims MAY also be returned.
Claims that return multiple values are represented as JSON arrays.
Claims with zero elements MUST be omitted from the response.
An example WebFinger discovery request follows. To find the authorization
server's configuration information for the resource
https://finance.example.com/abcpath",
the WebFinger parameters are as follows:
WebFinger ParameterValueresourcehttps://finance.example.com/abcpathhostexample.comreloauth2
The discovered authorization server is identified as
https://server.example.com.
In the event that the authorization server does not support the requested
resource, the server MUST indicate
that it was unable to match the request as per Section 4.2.
If any of the validation procedures defined in this specification fail, any operations requiring
the information that failed to correctly validate MUST be aborted and
the information that failed to validate MUST NOT be used.
The issuer value returned MUST be identical to
the configuration information location URL that was directly used to retrieve the configuration information.
Authorization servers can have metadata describing their configuration.
These authorization server metadata values are used by this specification:
REQUIRED.
The authorization server's issuer identifier, which is a URL that
uses the https scheme and has no query or fragment components.
This is the location where
.well-knownRFC 5785 resources
containing information about the authorization server are published.
Using these well-known resources is described in .
The issuer identifier is used to prevent authorization server mix-up attacks,
as described in
"OAuth 2.0 Mix-Up Mitigation".
REQUIRED.
URL of the authorization server's authorization endpoint .
URL of the authorization server's token endpoint .
This is REQUIRED unless only the implicit grant type is used.
RECOMMMENDED.
URL of the authorization server's JWK Set document.
This contains the signing key(s) the client uses to validate signatures from the authorization server.
The JWK Set MAY also contain the Server's encryption key(s),
which are used by RPs to encrypt requests to the Server.
When both signing and encryption keys are made available,
a use (public key use) parameter
value is REQUIRED for all keys in the referenced JWK Set
to indicate each key's intended usage.
Although some algorithms allow the same key to be used for
both signatures and encryption, doing so is
NOT RECOMMENDED, as it is less secure.
The JWK x5c parameter MAY be used
to provide X.509 representations of keys provided. When used, the bare key
values MUST still be present and MUST match those in the certificate.
RECOMMENDED.
URL of the authorization server's OAuth 2.0 Dynamic Client Registration endpoint .
RECOMMENDED.
JSON array containing a list of the OAuth 2.0scope values that this authorization server supports.
Servers MAY choose not to advertise some supported scope values
even when this parameter is used.
REQUIRED.
JSON array containing a list of the OAuth 2.0
response_type values that this
authorization server supports.
OPTIONAL.
JSON array containing a list of the OAuth 2.0
response_mode values that this
authorization server supports, as specified in
OAuth 2.0 Multiple Response Type Encoding Practices.
If omitted, the default is
["query", "fragment"].
The response mode value form_post is also defined in
OAuth 2.0 Form Post Response Mode.
OPTIONAL.
JSON array containing a list of the OAuth 2.0
grant type values that this
authorization server supports.
If omitted, the default value is
["authorization_code", "implicit"].
OPTIONAL.
JSON array containing a list of client authentication methods
supported by this token endpoint.
Client authentication method values are used in the
token_endpoint_auth_method
parameter defined in Section 2 of .
If omitted, the default is client_secret_basic --
the HTTP Basic Authentication Scheme specified in
Section 2.3.1 of OAuth 2.0.
OPTIONAL.
JSON array containing a list of the JWS signing algorithms
(alg values)
supported by the token endpoint for the signature on
the JWT used to authenticate the client
at the token endpoint for the private_key_jwt
and client_secret_jwt authentication methods.
Servers SHOULD support RS256.
The value none MUST NOT be used.
OPTIONAL.
URL of a page containing human-readable information that
developers might want or need to know when using the authorization server.
In particular, if the authorization server does not support Dynamic Client Registration,
then information on how to register clients needs to be provided in this documentation.
OPTIONAL.
Languages and scripts supported for the user interface,
represented as a JSON array of
BCP47 language tag values.
OPTIONAL.
URL that the authorization server provides to the person registering
the client to read about the authorization server's requirements on how
the client can use the data provided by the authorization server.
The registration process SHOULD display this
URL to the person registering the client if it is given.
As described in , despite the identifier
op_policy_uri,
appearing to be OpenID-specific,
its usage in this specification is actually referring to
a general OAuth 2.0 feature that is not specific to OpenID Connect.
OPTIONAL.
URL that the authorization server provides to the person registering
the client to read about authorization server's terms of service.
The registration process SHOULD display this
URL to the person registering the client if it is given.
As described in , despite the identifier
op_tos_uri,
appearing to be OpenID-specific,
its usage in this specification is actually referring to
a general OAuth 2.0 feature that is not specific to OpenID Connect.
OPTIONAL.
URL of the authorization server's OAuth 2.0 revocation endpoint .
OPTIONAL.
JSON array containing a list of client authentication methods
supported by this revocation endpoint.
The valid client authentication method values are those registered
in the IANA "OAuth Token Endpoint Authentication Methods" registry
.
OPTIONAL.
JSON array containing a list of the JWS signing algorithms
(alg values)
supported by the revocation endpoint for the signature on
the JWT used to authenticate the client
at the revocation endpoint for the private_key_jwt
and client_secret_jwt authentication methods.
The value none MUST NOT be used.
OPTIONAL.
URL of the authorization server's OAuth 2.0 introspection endpoint .
OPTIONAL.
JSON array containing a list of client authentication methods
supported by this introspection endpoint.
The valid client authentication method values are those registered
in the IANA "OAuth Token Endpoint Authentication Methods" registry
or those registered
in the IANA "OAuth Access Token Types" registry
.
(These values are and will remain distinct,
due to .)
OPTIONAL.
JSON array containing a list of the JWS signing algorithms
(alg values)
supported by the introspection endpoint for the signature on
the JWT used to authenticate the client
at the introspection endpoint for the private_key_jwt
and client_secret_jwt authentication methods.
The value none MUST NOT be used.
OPTIONAL.
JSON array containing a list of PKCE
code challenge methods supported by this authorization server.
Code challenge method values are used in the
code_challenge_method
parameter defined in Section 4.3 of .
The valid code challenge method values are those registered
in the IANA "PKCE Code Challenge Methods" registry
.
Additional authorization server metadata parameters MAY also be used.
Some are defined by other specifications,
such as
OpenID Connect Discovery 1.0.
Processing some OAuth 2.0 messages requires comparing
values in the messages to known values. For example, the
member names in the configuration information response might be
compared to specific member names such as issuer. Comparing Unicode strings,
however, has significant security implications.
Therefore, comparisons between JSON strings and other Unicode
strings MUST be performed as specified below:
Remove any JSON applied escaping to produce an array of
Unicode code points.
Unicode Normalization MUST NOT
be applied at any point to either the JSON string or to
the string it is to be compared against.
Comparisons between the two strings MUST be performed as a
Unicode code point to code point equality comparison.
The identifiers
op_policy_uri,
and op_tos_uri
contain strings referring to the
OpenID Connect family of specifications
that were originally defined by
"OpenID Connect Discovery 1.0".
Despite the reuse of these identifiers that appear to be OpenID-specific,
their usage in this specification is actually referring to
general OAuth 2.0 features that are not specific to OpenID Connect.
Implementations MUST support TLS.
Which version(s) ought to be implemented will vary over
time, and depend on the widespread deployment and known
security vulnerabilities at the time of implementation.
The authorization server MUST support
TLS version 1.2
and MAY support additional transport-layer security mechanisms meeting its security requirements.
When using TLS, the client MUST perform a TLS/SSL server certificate check,
per RFC 6125.
Implementation security considerations can be found in
Recommendations for Secure Use of TLS and DTLS.
To protect against information disclosure and tampering,
confidentiality protection MUST be applied using TLS
with a ciphersuite that provides confidentiality and
integrity protection.
TLS certificate checking MUST be performed by the client,
as described in ,
when making an authorization server configuration information request.
Checking that the server certificate is valid for the configuration information location URL
prevents man-in-middle and DNS-based attacks.
These attacks could cause a client to be tricked into using an attacker's
keys and endpoints, which would enable impersonation of the legitimate authorization server.
If an attacker can accomplish this, they can access the resources
that the affected client has access to
using the authorization server that they are impersonating.
An attacker may also attempt to impersonate an authorization server by publishing
a discovery document that contains an issuer claim
using the configuration information location URL of the authorization server being impersonated,
but with its own endpoints and signing keys.
This would enable it to impersonate that authorization server, if accepted by the client.
To prevent this, RPs MUST ensure that the configuration information location URL they are using
for the configuration information request exactly matches the value of
the issuer metadata value
in the authorization server configuration information document received by the client.
This section registers the WebFinger link relation type oauth2
as per Section 6.2.1 of .oauth2Refers to discovery of OAuth2 configuration metadata.This specification.
This specification establishes the
IANA "OAuth Discovery Metadata" registry
for OAuth 2.0 authorization server metadata names.
The registry records the authorization server metadata member
and a reference to the specification that defines it.
The following registration procedure is used for the
registry established by this specification.
Values are registered on a Specification Required
basis after a two-week review period on the oauth-ext-review@ietf.org
mailing list, on the advice of one or more Designated Experts.
However, to allow for the allocation of values prior to publication,
the Designated Experts may approve registration once they are satisfied
that such a specification will be published.
Registration requests sent to the mailing list for review should use
an appropriate subject
(e.g., "Request to register OAuth Discovery Metadata: example").
Within the review period, the Designated Experts will either approve or
deny the registration request, communicating this decision to the review list and IANA.
Denials should include an explanation and, if applicable, suggestions as to how to make
the request successful.
Registration requests that are undetermined for
a period longer than 21 days can be brought to the IESG's attention
(using the iesg@ietf.org mailing list) for resolution.
Criteria that should be applied by the Designated Experts includes
determining whether the proposed registration duplicates existing functionality,
determining whether it is likely to be of general applicability
or whether it is useful only for a single application,
and whether the registration makes sense.
IANA must only accept registry updates from the Designated Experts and should direct
all requests for registration to the review mailing list.
It is suggested that multiple Designated Experts be appointed who are able to
represent the perspectives of different applications using this specification,
in order to enable broadly-informed review of registration decisions.
In cases where a registration decision could be perceived as
creating a conflict of interest for a particular Expert,
that Expert should defer to the judgment of the other Experts.
The name requested (e.g., "issuer").
This name is case-sensitive.
Names may not match other registered names in a case-insensitive manner
unless the Designated Experts state that there is a compelling reason
to allow an exception.
Brief description of the discovery metadata (e.g., "Issuer URL").
For Standards Track RFCs, list the "IESG".
For others, give the name of the responsible party.
Other details (e.g., postal address, email address, home page URI) may also be included.
Reference to the document or documents that specify the parameter,
preferably including URIs that
can be used to retrieve copies of the documents.
An indication of the relevant
sections may also be included but is not required.
Discovery Metadata Name: issuer
Discovery Metadata Description:
URL of the authorization server's configuration information location
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: authorization_endpoint
Discovery Metadata Description:
URL of the authorization server's authorization endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: token_endpoint
Discovery Metadata Description:
URL of the authorization server's token endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: jwks_uri
Discovery Metadata Description:
URL of the authorization server's JWK Set document
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: registration_endpoint
Discovery Metadata Description:
URL of the authorization server's OAuth 2.0 Dynamic Client Registration Endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: scopes_supported
Discovery Metadata Description:
JSON array containing a list of the OAuth 2.0
scope values that this authorization server supports
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: response_types_supported
Discovery Metadata Description:
JSON array containing a list of the OAuth 2.0
response_type values that this
authorization server supports
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: response_modes_supported
Discovery Metadata Description:
JSON array containing a list of the OAuth 2.0
response_mode values that this
authorization server supports
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: grant_types_supported
Discovery Metadata Description:
JSON array containing a list of the OAuth 2.0
grant type values that this
authorization server supports
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: token_endpoint_auth_methods_supported
Discovery Metadata Description:
JSON array containing a list of client authentication methods
supported by this token endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: token_endpoint_auth_signing_alg_values_supported
Discovery Metadata Description:
JSON array containing a list of the JWS signing algorithms
supported by the token endpoint for the signature on
the JWT used to authenticate the client
at the token endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: service_documentation
Discovery Metadata Description:
URL of a page containing human-readable information that
developers might want or need to know when using the authorization server
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: ui_locales_supported
Discovery Metadata Description:
Languages and scripts supported for the user interface,
represented as a JSON array of
BCP47 language tag values
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: op_policy_uri
Discovery Metadata Description:
URL that the authorization server provides to the person registering
the client to read about the authorization server's requirements on how
the client can use the data provided by the authorization server
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: op_tos_uri
Discovery Metadata Description:
URL that the authorization server provides to the person registering
the client to read about authorization server's terms of service
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: revocation_endpoint
Discovery Metadata Description:
URL of the authorization server's OAuth 2.0 revocation endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: revocation_endpoint_auth_methods_supported
Discovery Metadata Description:
JSON array containing a list of client authentication methods
supported by this revocation endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: revocation_endpoint_auth_signing_alg_values_supported
Discovery Metadata Description:
JSON array containing a list of the JWS signing algorithms
supported by the revocation endpoint for the signature on
the JWT used to authenticate the client
at the revocation endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: introspection_endpoint
Discovery Metadata Description:
URL of the authorization server's OAuth 2.0 introspection endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: introspection_endpoint_auth_methods_supported
Discovery Metadata Description:
JSON array containing a list of client authentication methods
supported by this introspection endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: introspection_endpoint_auth_signing_alg_values_supported
Discovery Metadata Description:
JSON array containing a list of the JWS signing algorithms
supported by the introspection endpoint for the signature on
the JWT used to authenticate the client
at the introspection endpoint
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
Discovery Metadata Name: code_challenge_methods_supported
Discovery Metadata Description:
PKCE code challenge methods supported by this authorization server
Change Controller: IESG
Specification Document(s): of [[ this specification ]]
This specification adds to the instructions for the Designated Experts
of the following IANA registries, both of which are in the
"OAuth Parameters" registry
:
OAuth Access Token Types
OAuth Token Endpoint Authentication Methods
IANA has added a link to this specification in the Reference sections
of these registries.
[[ RFC Editor: The above sentence is written in the past tense
as it would appear in the final specification, even though these
links won't actually be created until after the IESG has requested
publication of the specification.
Please delete this note after the links are in place. ]]
For these registries, the designated experts must reject
registration requests in one registry
for values already occurring in the other registry.
This is necessary because the
introspection_endpoint_auth_methods_supported
parameter allows for the use of values from either registry.
That way, because the values in the two registries will continue to be
mutually exclusive, no ambiguities will arise.
Recommendations for Secure Use of Transport Layer Security (TLS) and Datagram Transport Layer Security (DTLS)Transport Layer Security (TLS) and Datagram Transport Layer Security (DTLS) are widely used to protect data exchanged over application protocols such as HTTP, SMTP, IMAP, POP, SIP, and XMPP. Over the last few years, several serious attacks on TLS have emerged, including attacks on its most commonly used cipher suites and their modes of operation. This document provides recommendations for improving the security of deployed services that use TLS and DTLS. The recommendations are applicable to the majority of use cases.Unicode Normalization FormsJSON Web Token (JWT)MicrosoftPing IdentityNomura Research Institute, Ltd.JSON Web Signature (JWS)MicrosoftPing IdentityNomura Research Institute, Ltd.JSON Web Encryption (JWE)MicrosoftCisco Systems, Inc.JSON Web Algorithms (JWA)MicrosoftJSON Web Key (JWK)MicrosoftOAuth 2.0 Multiple Response Type Encoding PracticesGoogleGoogle FacebookMicrosoftOAuth 2.0 Form Post Response ModeMicrosoftPing IdentityOAuth ParametersIANAThe Unicode StandardThe Unicode ConsortiumOpenID Connect Core 1.0Nomura Research Institute, Ltd.Ping IdentityMicrosoftGoogleSalesforceOpenID Connect Discovery 1.0Nomura Research Institute,
Ltd.Ping IdentityMicrosoftIllumilaOpenID Connect Dynamic Client Registration 1.0Nomura Research Institute, Ltd.Ping IdentityMicrosoftThis specification is an alternate proposal to the OAuth 2.0 Discovery
working group draft (draft-ietf-oauth-discovery-01) and contains substantial
text from this draft. The author would like to thank the original draft authors
Mike Jones, Nat Sakimura, and John Bradley as well as the OAuth Working Group.
This specification is based in part on the OpenID Connect Discovery 1.0 specification,
which was produced by the OpenID Connect working group of the OpenID Foundation.
[[ to be removed by the RFC Editor before publication as an RFC ]]
-00
Created the initial working group version based on draft-jones-oauth-discovery-01,
with no normative changes.