idnits 2.17.1 draft-ietf-oauth-discovery-10.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (March 4, 2018) is 2207 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) ** Obsolete normative reference: RFC 7525 (ref. 'BCP195') (Obsoleted by RFC 9325) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 5785 (Obsoleted by RFC 8615) ** Obsolete normative reference: RFC 6125 (Obsoleted by RFC 9525) ** Obsolete normative reference: RFC 7159 (Obsoleted by RFC 8259) -- Possible downref: Non-RFC (?) normative reference: ref. 'UNICODE' -- Possible downref: Non-RFC (?) normative reference: ref. 'USA15' Summary: 5 errors (**), 0 flaws (~~), 1 warning (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 OAuth Working Group M. Jones 3 Internet-Draft Microsoft 4 Intended status: Standards Track N. Sakimura 5 Expires: September 5, 2018 NRI 6 J. Bradley 7 Ping Identity 8 March 4, 2018 10 OAuth 2.0 Authorization Server Metadata 11 draft-ietf-oauth-discovery-10 13 Abstract 15 This specification defines a metadata format that an OAuth 2.0 client 16 can use to obtain the information needed to interact with an OAuth 17 2.0 authorization server, including its endpoint locations and 18 authorization server capabilities. 20 Status of This Memo 22 This Internet-Draft is submitted in full conformance with the 23 provisions of BCP 78 and BCP 79. 25 Internet-Drafts are working documents of the Internet Engineering 26 Task Force (IETF). Note that other groups may also distribute 27 working documents as Internet-Drafts. The list of current Internet- 28 Drafts is at https://datatracker.ietf.org/drafts/current/. 30 Internet-Drafts are draft documents valid for a maximum of six months 31 and may be updated, replaced, or obsoleted by other documents at any 32 time. It is inappropriate to use Internet-Drafts as reference 33 material or to cite them other than as "work in progress." 35 This Internet-Draft will expire on September 5, 2018. 37 Copyright Notice 39 Copyright (c) 2018 IETF Trust and the persons identified as the 40 document authors. All rights reserved. 42 This document is subject to BCP 78 and the IETF Trust's Legal 43 Provisions Relating to IETF Documents 44 (https://trustee.ietf.org/license-info) in effect on the date of 45 publication of this document. Please review these documents 46 carefully, as they describe your rights and restrictions with respect 47 to this document. Code Components extracted from this document must 48 include Simplified BSD License text as described in Section 4.e of 49 the Trust Legal Provisions and are provided without warranty as 50 described in the Simplified BSD License. 52 Table of Contents 54 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 55 1.1. Requirements Notation and Conventions . . . . . . . . . . 3 56 1.2. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3 57 2. Authorization Server Metadata . . . . . . . . . . . . . . . . 4 58 2.1. Signed Authorization Server Metadata . . . . . . . . . . 7 59 3. Obtaining Authorization Server Metadata . . . . . . . . . . . 8 60 3.1. Authorization Server Metadata Request . . . . . . . . . . 9 61 3.2. Authorization Server Metadata Response . . . . . . . . . 9 62 3.3. Authorization Server Metadata Validation . . . . . . . . 10 63 4. String Operations . . . . . . . . . . . . . . . . . . . . . . 11 64 5. Compatibility Notes . . . . . . . . . . . . . . . . . . . . . 11 65 6. Security Considerations . . . . . . . . . . . . . . . . . . . 12 66 6.1. TLS Requirements . . . . . . . . . . . . . . . . . . . . 12 67 6.2. Impersonation Attacks . . . . . . . . . . . . . . . . . . 12 68 6.3. Publishing Metadata in a Standard Format . . . . . . . . 13 69 6.4. Protected Resources . . . . . . . . . . . . . . . . . . . 13 70 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 13 71 7.1. OAuth Authorization Server Metadata Registry . . . . . . 14 72 7.1.1. Registration Template . . . . . . . . . . . . . . . . 15 73 7.1.2. Initial Registry Contents . . . . . . . . . . . . . . 15 74 7.2. Updated Registration Instructions . . . . . . . . . . . . 18 75 7.3. Well-Known URI Registry . . . . . . . . . . . . . . . . . 19 76 7.3.1. Registry Contents . . . . . . . . . . . . . . . . . . 19 77 8. References . . . . . . . . . . . . . . . . . . . . . . . . . 19 78 8.1. Normative References . . . . . . . . . . . . . . . . . . 19 79 8.2. Informative References . . . . . . . . . . . . . . . . . 21 80 Appendix A. Acknowledgements . . . . . . . . . . . . . . . . . . 22 81 Appendix B. Document History . . . . . . . . . . . . . . . . . . 22 82 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 25 84 1. Introduction 86 This specification generalizes the metadata format defined by "OpenID 87 Connect Discovery 1.0" [OpenID.Discovery] in a way that is compatible 88 with OpenID Connect Discovery, while being applicable to a wider set 89 of OAuth 2.0 use cases. This is intentionally parallel to the way 90 that the "OAuth 2.0 Dynamic Client Registration Protocol" [RFC7591] 91 specification generalized the dynamic client registration mechanisms 92 defined by "OpenID Connect Dynamic Client Registration 1.0" 93 [OpenID.Registration] in a way that was compatible with it. 95 The metadata for an authorization server is retrieved from a well- 96 known location as a JSON [RFC7159] document, which declares its 97 endpoint locations and authorization server capabilities. This 98 process is described in Section 3. 100 This metadata can either be communicated in a self-asserted fashion 101 by the server origin via HTTPS or as a set of signed metadata values 102 represented as claims in a JSON Web Token (JWT) [JWT]. In the JWT 103 case, the issuer is vouching for the validity of the data about the 104 authorization server. This is analogous to the role that the 105 Software Statement plays in OAuth Dynamic Client Registration 106 [RFC7591]. 108 The means by which the client chooses an authorization server is out 109 of scope. In some cases, its issuer identifier may be manually 110 configured into the client. In other cases, it may be dynamically 111 discovered, for instance, through the use of WebFinger [RFC7033], as 112 described in Section 2 of "OpenID Connect Discovery 1.0" 113 [OpenID.Discovery]. 115 1.1. Requirements Notation and Conventions 117 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 118 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 119 "OPTIONAL" in this document are to be interpreted as described in BCP 120 14 [RFC2119] [RFC8174] when, and only when, they appear in all 121 capitals, as shown here. 123 All uses of JSON Web Signature (JWS) [JWS] and JSON Web Encryption 124 (JWE) [JWE] data structures in this specification utilize the JWS 125 Compact Serialization or the JWE Compact Serialization; the JWS JSON 126 Serialization and the JWE JSON Serialization are not used. 128 1.2. Terminology 130 This specification uses the terms "Access Token", "Authorization 131 Code", "Authorization Endpoint", "Authorization Grant", 132 "Authorization Server", "Client", "Client Authentication", "Client 133 Identifier", "Client Secret", "Grant Type", "Protected Resource", 134 "Redirection URI", "Refresh Token", "Resource Owner", "Resource 135 Server", "Response Type", and "Token Endpoint" defined by OAuth 2.0 136 [RFC6749], the terms "Claim Name", "Claim Value", and "JSON Web Token 137 (JWT)" defined by JSON Web Token (JWT) [JWT], and the term "Response 138 Mode" defined by OAuth 2.0 Multiple Response Type Encoding Practices 139 [OAuth.Responses]. 141 2. Authorization Server Metadata 143 Authorization servers can have metadata describing their 144 configuration. The following authorization server metadata values 145 are used by this specification and are registered in the IANA "OAuth 146 Authorization Server Metadata" registry established in Section 7.1: 148 issuer 149 REQUIRED. The authorization server's issuer identifier, which is 150 a URL that uses the "https" scheme and has no query or fragment 151 components. Authorization server metadata is published at a 152 ".well-known" RFC 5785 [RFC5785] location derived from this issuer 153 identifier, as described in Section 3. The issuer identifier is 154 used to prevent authorization server mix-up attacks, as described 155 in "OAuth 2.0 Mix-Up Mitigation" 156 [I-D.ietf-oauth-mix-up-mitigation]. 158 authorization_endpoint 159 URL of the authorization server's authorization endpoint 160 [RFC6749]. This is REQUIRED unless no grant types are supported 161 that use the authorization endpoint. 163 token_endpoint 164 URL of the authorization server's token endpoint [RFC6749]. This 165 is REQUIRED unless only the implicit grant type is supported. 167 jwks_uri 168 OPTIONAL. URL of the authorization server's JWK Set [JWK] 169 document. The referenced document contains the signing key(s) the 170 client uses to validate signatures from the authorization server. 171 This URL MUST use the "https" scheme. The JWK Set MAY also 172 contain the server's encryption key(s), which are used by clients 173 to encrypt requests to the server. When both signing and 174 encryption keys are made available, a "use" (public key use) 175 parameter value is REQUIRED for all keys in the referenced JWK Set 176 to indicate each key's intended usage. 178 registration_endpoint 179 OPTIONAL. URL of the authorization server's OAuth 2.0 Dynamic 180 Client Registration endpoint [RFC7591]. 182 scopes_supported 183 RECOMMENDED. JSON array containing a list of the OAuth 2.0 184 [RFC6749] "scope" values that this authorization server supports. 185 Servers MAY choose not to advertise some supported scope values 186 even when this parameter is used. 188 response_types_supported 189 REQUIRED. JSON array containing a list of the OAuth 2.0 190 "response_type" values that this authorization server supports. 191 The array values used are the same as those used with the 192 "response_types" parameter defined by "OAuth 2.0 Dynamic Client 193 Registration Protocol" [RFC7591]. 195 response_modes_supported 196 OPTIONAL. JSON array containing a list of the OAuth 2.0 197 "response_mode" values that this authorization server supports, as 198 specified in OAuth 2.0 Multiple Response Type Encoding Practices 199 [OAuth.Responses]. If omitted, the default is "["query", 200 "fragment"]". The response mode value "form_post" is also defined 201 in OAuth 2.0 Form Post Response Mode [OAuth.Post]. 203 grant_types_supported 204 OPTIONAL. JSON array containing a list of the OAuth 2.0 grant 205 type values that this authorization server supports. The array 206 values used are the same as those used with the "grant_types" 207 parameter defined by "OAuth 2.0 Dynamic Client Registration 208 Protocol" [RFC7591]. If omitted, the default value is 209 "["authorization_code", "implicit"]". 211 token_endpoint_auth_methods_supported 212 OPTIONAL. JSON array containing a list of client authentication 213 methods supported by this token endpoint. Client authentication 214 method values are used in the "token_endpoint_auth_method" 215 parameter defined in Section 2 of [RFC7591]. If omitted, the 216 default is "client_secret_basic" -- the HTTP Basic Authentication 217 Scheme specified in Section 2.3.1 of OAuth 2.0 [RFC6749]. 219 token_endpoint_auth_signing_alg_values_supported 220 OPTIONAL. JSON array containing a list of the JWS signing 221 algorithms ("alg" values) supported by the token endpoint for the 222 signature on the JWT [JWT] used to authenticate the client at the 223 token endpoint for the "private_key_jwt" and "client_secret_jwt" 224 authentication methods. This metadata entry MUST be present if 225 either of these authentication methods are specified in the 226 "token_endpoint_auth_methods_supported" entry. No default 227 algorithms are implied if this entry is omitted. Servers SHOULD 228 support "RS256". The value "none" MUST NOT be used. 230 service_documentation 231 OPTIONAL. URL of a page containing human-readable information 232 that developers might want or need to know when using the 233 authorization server. In particular, if the authorization server 234 does not support Dynamic Client Registration, then information on 235 how to register clients needs to be provided in this 236 documentation. 238 ui_locales_supported 239 OPTIONAL. Languages and scripts supported for the user interface, 240 represented as a JSON array of BCP47 [RFC5646] language tag 241 values. If omitted, the set of supported languages and scripts is 242 unspecified. 244 op_policy_uri 245 OPTIONAL. URL that the authorization server provides to the 246 person registering the client to read about the authorization 247 server's requirements on how the client can use the data provided 248 by the authorization server. The registration process SHOULD 249 display this URL to the person registering the client if it is 250 given. As described in Section 5, despite the identifier 251 "op_policy_uri", appearing to be OpenID-specific, its usage in 252 this specification is actually referring to a general OAuth 2.0 253 feature that is not specific to OpenID Connect. 255 op_tos_uri 256 OPTIONAL. URL that the authorization server provides to the 257 person registering the client to read about the authorization 258 server's terms of service. The registration process SHOULD 259 display this URL to the person registering the client if it is 260 given. As described in Section 5, despite the identifier 261 "op_tos_uri", appearing to be OpenID-specific, its usage in this 262 specification is actually referring to a general OAuth 2.0 feature 263 that is not specific to OpenID Connect. 265 revocation_endpoint 266 OPTIONAL. URL of the authorization server's OAuth 2.0 revocation 267 endpoint [RFC7009]. 269 revocation_endpoint_auth_methods_supported 270 OPTIONAL. JSON array containing a list of client authentication 271 methods supported by this revocation endpoint. The valid client 272 authentication method values are those registered in the IANA 273 "OAuth Token Endpoint Authentication Methods" registry 274 [IANA.OAuth.Parameters]. If omitted, the default is 275 "client_secret_basic" -- the HTTP Basic Authentication Scheme 276 specified in Section 2.3.1 of OAuth 2.0 [RFC6749]. 278 revocation_endpoint_auth_signing_alg_values_supported 279 OPTIONAL. JSON array containing a list of the JWS signing 280 algorithms ("alg" values) supported by the revocation endpoint for 281 the signature on the JWT [JWT] used to authenticate the client at 282 the revocation endpoint for the "private_key_jwt" and 283 "client_secret_jwt" authentication methods. This metadata entry 284 MUST be present if either of these authentication methods are 285 specified in the "revocation_endpoint_auth_methods_supported" 286 entry. No default algorithms are implied if this entry is 287 omitted. The value "none" MUST NOT be used. 289 introspection_endpoint 290 OPTIONAL. URL of the authorization server's OAuth 2.0 291 introspection endpoint [RFC7662]. 293 introspection_endpoint_auth_methods_supported 294 OPTIONAL. JSON array containing a list of client authentication 295 methods supported by this introspection endpoint. The valid 296 client authentication method values are those registered in the 297 IANA "OAuth Token Endpoint Authentication Methods" registry 298 [IANA.OAuth.Parameters] or those registered in the IANA "OAuth 299 Access Token Types" registry [IANA.OAuth.Parameters]. (These 300 values are and will remain distinct, due to Section 7.2.) If 301 omitted, the set of supported authentication methods MUST be 302 determined by other means. 304 introspection_endpoint_auth_signing_alg_values_supported 305 OPTIONAL. JSON array containing a list of the JWS signing 306 algorithms ("alg" values) supported by the introspection endpoint 307 for the signature on the JWT [JWT] used to authenticate the client 308 at the introspection endpoint for the "private_key_jwt" and 309 "client_secret_jwt" authentication methods. This metadata entry 310 MUST be present if either of these authentication methods are 311 specified in the "introspection_endpoint_auth_methods_supported" 312 entry. No default algorithms are implied if this entry is 313 omitted. The value "none" MUST NOT be used. 315 code_challenge_methods_supported 316 OPTIONAL. JSON array containing a list of PKCE [RFC7636] code 317 challenge methods supported by this authorization server. Code 318 challenge method values are used in the "code_challenge_method" 319 parameter defined in Section 4.3 of [RFC7636]. The valid code 320 challenge method values are those registered in the IANA "PKCE 321 Code Challenge Methods" registry [IANA.OAuth.Parameters]. If 322 omitted, the authorization server does not support PKCE. 324 Additional authorization server metadata parameters MAY also be used. 325 Some are defined by other specifications, such as OpenID Connect 326 Discovery 1.0 [OpenID.Discovery]. 328 2.1. Signed Authorization Server Metadata 330 In addition to JSON elements, metadata values MAY also be provided as 331 a "signed_metadata" value, which is a JSON Web Token (JWT) [JWT] that 332 asserts metadata values about the authorization server as a bundle. 333 A set of claims that can be used in signed metadata are defined in 334 Section 2. The signed metadata MUST be digitally signed or MACed 335 using JSON Web Signature (JWS) [JWS] and MUST contain an "iss" 336 (issuer) claim denoting the party attesting to the claims in the 337 signed metadata. Consumers of the metadata MAY ignore the signed 338 metadata if they do not support this feature. If the consumer of the 339 metadata supports signed metadata, metadata values conveyed in the 340 signed metadata MUST take precedence over the corresponding values 341 conveyed using plain JSON elements. 343 Signed metadata is included in the authorization server metadata JSON 344 object using this OPTIONAL member: 346 signed_metadata 347 A JWT containing metadata values about the authorization server as 348 claims. This is a string value consisting of the entire signed 349 JWT. A "signed_metadata" metadata value SHOULD NOT appear as a 350 claim in the JWT. 352 3. Obtaining Authorization Server Metadata 354 Authorization servers supporting metadata MUST make a JSON document 355 containing metadata as specified in Section 2 available at a path 356 formed by inserting a well-known URI string into the authorization 357 server's issuer identifier between the host component and the path 358 component, if any. By default, the well-known URI string used is 359 "/.well-known/oauth-authorization-server". This path MUST use the 360 "https" scheme. The syntax and semantics of ".well-known" are 361 defined in RFC 5785 [RFC5785]. The well-known URI suffix used MUST 362 be registered in the IANA "Well-Known URIs" registry 363 [IANA.well-known]. 365 Different applications utilizing OAuth authorization servers in 366 application-specific ways may define and register different well- 367 known URI suffixes used to publish authorization server metadata as 368 used by those applications. For instance, if the Example application 369 uses an OAuth authorization server in an Example-specific way, and 370 there are Example-specific metadata values that it needs to publish, 371 then it might register and use the "example-configuration" URI suffix 372 and publish the metadata document at the path formed by inserting 373 "/.well-known/example-configuration" between the host and path 374 components of the authorization server's issuer identifier. 375 Alternatively, many such applications will use the default well-known 376 URI string "/.well-known/oauth-authorization-server", which is the 377 right choice for general-purpose OAuth authorization servers, and not 378 register an application-specific one. 380 An OAuth 2.0 application using this specification MUST specify what 381 well-known URI suffix it will use for this purpose. The same 382 authorization server MAY choose to publish its metadata at multiple 383 well-known locations derived from its issuer identifier, for example, 384 publishing metadata at both "/.well-known/example-configuration" and 385 "/.well-known/oauth-authorization-server". 387 Some OAuth applications will choose to use the well-known URI suffix 388 "openid-configuration". As described in Section 5, despite the 389 identifier "/.well-known/openid-configuration", appearing to be 390 OpenID-specific, its usage in this specification is actually 391 referring to a general OAuth 2.0 feature that is not specific to 392 OpenID Connect. 394 3.1. Authorization Server Metadata Request 396 An authorization server metadata document MUST be queried using an 397 HTTP "GET" request at the previously specified path. 399 The client would make the following request when the issuer 400 identifier is "https://example.com" and the well-known URI suffix is 401 "oauth-authorization-server" to obtain the metadata, since the issuer 402 identifier contains no path component: 404 GET /.well-known/oauth-authorization-server HTTP/1.1 405 Host: example.com 407 If the issuer identifier value contains a path component, any 408 terminating "/" MUST be removed before inserting "/.well-known/" and 409 the well-known URI suffix between the host component and the path 410 component. The client would make the following request when the 411 issuer identifier is "https://example.com/issuer1" and the well-known 412 URI suffix is "oauth-authorization-server" to obtain the metadata, 413 since the issuer identifier contains a path component: 415 GET /.well-known/oauth-authorization-server/issuer1 HTTP/1.1 416 Host: example.com 418 Using path components enables supporting multiple issuers per host. 419 This is required in some multi-tenant hosting configurations. This 420 use of ".well-known" is for supporting multiple issuers per host; 421 unlike its use in RFC 5785 [RFC5785], it does not provide general 422 information about the host. 424 3.2. Authorization Server Metadata Response 426 The response is a set of claims about the authorization server's 427 configuration, including all necessary endpoints and public key 428 location information. A successful response MUST use the 200 OK HTTP 429 status code and return a JSON object using the "application/json" 430 content type that contains a set of claims as its members that are a 431 subset of the metadata values defined in Section 2. Other claims MAY 432 also be returned. 434 Claims that return multiple values are represented as JSON arrays. 435 Claims with zero elements MUST be omitted from the response. 437 An error response uses the applicable HTTP status code value. 439 The following is a non-normative example response: 441 HTTP/1.1 200 OK 442 Content-Type: application/json 444 { 445 "issuer": 446 "https://server.example.com", 447 "authorization_endpoint": 448 "https://server.example.com/authorize", 449 "token_endpoint": 450 "https://server.example.com/token", 451 "token_endpoint_auth_methods_supported": 452 ["client_secret_basic", "private_key_jwt"], 453 "token_endpoint_auth_signing_alg_values_supported": 454 ["RS256", "ES256"], 455 "userinfo_endpoint": 456 "https://server.example.com/userinfo", 457 "jwks_uri": 458 "https://server.example.com/jwks.json", 459 "registration_endpoint": 460 "https://server.example.com/register", 461 "scopes_supported": 462 ["openid", "profile", "email", "address", 463 "phone", "offline_access"], 464 "response_types_supported": 465 ["code", "code token"], 466 "service_documentation": 467 "http://server.example.com/service_documentation.html", 468 "ui_locales_supported": 469 ["en-US", "en-GB", "en-CA", "fr-FR", "fr-CA"] 470 } 472 3.3. Authorization Server Metadata Validation 474 The "issuer" value returned MUST be identical to the authorization 475 server's issuer identifier value into which the well-known URI string 476 was inserted to create the URL used to retrieve the metadata. If 477 these values are not identical, the data contained in the response 478 MUST NOT be used. 480 4. String Operations 482 Processing some OAuth 2.0 messages requires comparing values in the 483 messages to known values. For example, the member names in the 484 metadata response might be compared to specific member names such as 485 "issuer". Comparing Unicode [UNICODE] strings, however, has 486 significant security implications. 488 Therefore, comparisons between JSON strings and other Unicode strings 489 MUST be performed as specified below: 491 1. Remove any JSON applied escaping to produce an array of Unicode 492 code points. 494 2. Unicode Normalization [USA15] MUST NOT be applied at any point to 495 either the JSON string or to the string it is to be compared 496 against. 498 3. Comparisons between the two strings MUST be performed as a 499 Unicode code point to code point equality comparison. 501 Note that this is the same equality comparison procedure described in 502 Section 8.3 of [RFC7159]. 504 5. Compatibility Notes 506 The identifiers "/.well-known/openid-configuration", "op_policy_uri", 507 and "op_tos_uri" contain strings referring to the OpenID Connect 508 [OpenID.Core] family of specifications that were originally defined 509 by "OpenID Connect Discovery 1.0" [OpenID.Discovery]. Despite the 510 reuse of these identifiers that appear to be OpenID-specific, their 511 usage in this specification is actually referring to general OAuth 512 2.0 features that are not specific to OpenID Connect. 514 The algorithm for transforming the issuer identifier to an 515 authorization server metadata location defined in Section 3 is 516 equivalent to the corresponding transformation defined in Section 4 517 of "OpenID Connect Discovery 1.0" [OpenID.Discovery], provided that 518 the issuer identifier contains no path component. However, they are 519 different when there is a path component, because OpenID Connect 520 Discovery 1.0 specifies that the well-known URI string is appended to 521 the issuer identifier (e.g., "https://example.com/issuer1/.well- 522 known/openid-configuration"), whereas this specification specifies 523 that the well-known URI string is inserted before the path component 524 of the issuer identifier (e.g., "https://example.com/.well-known/ 525 openid-configuration/issuer1"). 527 Going forward, OAuth authorization server metadata locations should 528 use the transformation defined in this specification. However, when 529 deployed in legacy environments in which the OpenID Connect Discovery 530 1.0 transformation is already used, it may be necessary during a 531 transition period to publish metadata for issuer identifiers 532 containing a path component at both locations. During this 533 transition period, applications should first apply the transformation 534 defined in this specification and attempt to retrieve the 535 authorization server metadata from the resulting location; only if 536 the retrieval from that location fails should they fall back to 537 attempting to retrive it from the alternate location obtained using 538 the transformation defined by OpenID Connect Discovery 1.0. This 539 backwards-compatibility behavior should only be necessary when the 540 well-known URI suffix employed by the application is "openid- 541 configuration". 543 6. Security Considerations 545 6.1. TLS Requirements 547 Implementations MUST support TLS. Which version(s) ought to be 548 implemented will vary over time and depend on the widespread 549 deployment and known security vulnerabilities at the time of 550 implementation. The authorization server MUST support TLS version 551 1.2 [RFC5246] and MAY support additional transport-layer security 552 mechanisms meeting its security requirements. When using TLS, the 553 client MUST perform a TLS/SSL server certificate check, per RFC 6125 554 [RFC6125]. Implementation security considerations can be found in 555 Recommendations for Secure Use of TLS and DTLS [BCP195]. 557 To protect against information disclosure and tampering, 558 confidentiality protection MUST be applied using TLS with a 559 ciphersuite that provides confidentiality and integrity protection. 561 6.2. Impersonation Attacks 563 TLS certificate checking MUST be performed by the client, as 564 described in Section 6.1, when making an authorization server 565 metadata request. Checking that the server certificate is valid for 566 the issuer identifier URL prevents man-in-middle and DNS-based 567 attacks. These attacks could cause a client to be tricked into using 568 an attacker's keys and endpoints, which would enable impersonation of 569 the legitimate authorization server. If an attacker can accomplish 570 this, they can access the resources that the affected client has 571 access to using the authorization server that they are impersonating. 573 An attacker may also attempt to impersonate an authorization server 574 by publishing a metadata document that contains an "issuer" claim 575 using the issuer identifier URL of the authorization server being 576 impersonated, but with its own endpoints and signing keys. This 577 would enable it to impersonate that authorization server, if accepted 578 by the client. To prevent this, the client MUST ensure that the 579 issuer identifier URL it is using as the prefix for the metadata 580 request exactly matches the value of the "issuer" metadata value in 581 the authorization server metadata document received by the client. 583 6.3. Publishing Metadata in a Standard Format 585 Publishing information about the authorization server in a standard 586 format makes it easier for both legitimate clients and attackers to 587 use the authorization server. Whether an authorization server 588 publishes its metadata in an ad-hoc manner or in the standard format 589 defined by this specification, the same defenses against attacks that 590 might be mounted that use this information should be applied. 592 6.4. Protected Resources 594 Secure determination of appropriate protected resources to use with 595 an authorization server for all use cases is out of scope of this 596 specification. This specification assumes that the client has a 597 means of determining appropriate protected resources to use with an 598 authorization server and that the client is using the correct 599 metadata for each authorization server. Implementers need to be 600 aware that if an inappropriate protected resource is used by the 601 client, that an attacker may be able to act as a man-in-the-middle 602 proxy to a valid protected resource without it being detected by the 603 authorization server or the client. 605 The ways to determine the appropriate protected resources to use with 606 an authorization server are in general, application-dependent. For 607 instance, some authorization servers are used with a fixed protected 608 resource or set of protected resources, the locations of which may be 609 well known, or which could be published as metadata values by the 610 authorization server. In other cases, the set of resources that can 611 be used with an authorization server can by dynamically changed by 612 administrative actions. Many other means of determining appropriate 613 associations between authorization servers and protected resources 614 are also possible. 616 7. IANA Considerations 618 The following registration procedure is used for the registry 619 established by this specification. 621 Values are registered on a Specification Required [RFC8126] basis 622 after a two-week review period on the oauth-ext-review@ietf.org 623 mailing list, on the advice of one or more Designated Experts. 624 However, to allow for the allocation of values prior to publication, 625 the Designated Experts may approve registration once they are 626 satisfied that such a specification will be published. 628 Registration requests sent to the mailing list for review should use 629 an appropriate subject (e.g., "Request to register OAuth 630 Authorization Server Metadata: example"). 632 Within the review period, the Designated Experts will either approve 633 or deny the registration request, communicating this decision to the 634 review list and IANA. Denials should include an explanation and, if 635 applicable, suggestions as to how to make the request successful. 636 Registration requests that are undetermined for a period longer than 637 21 days can be brought to the IESG's attention (using the 638 iesg@ietf.org mailing list) for resolution. 640 Criteria that should be applied by the Designated Experts includes 641 determining whether the proposed registration duplicates existing 642 functionality, determining whether it is likely to be of general 643 applicability or whether it is useful only for a single application, 644 and whether the registration makes sense. 646 IANA must only accept registry updates from the Designated Experts 647 and should direct all requests for registration to the review mailing 648 list. 650 It is suggested that multiple Designated Experts be appointed who are 651 able to represent the perspectives of different applications using 652 this specification, in order to enable broadly-informed review of 653 registration decisions. In cases where a registration decision could 654 be perceived as creating a conflict of interest for a particular 655 Expert, that Expert should defer to the judgment of the other 656 Experts. 658 7.1. OAuth Authorization Server Metadata Registry 660 This specification establishes the IANA "OAuth Authorization Server 661 Metadata" registry for OAuth 2.0 authorization server metadata names. 662 The registry records the authorization server metadata member and a 663 reference to the specification that defines it. 665 The Designated Experts must either: 667 (a) require that metadata names and values being registered use only 668 printable ASCII characters excluding double quote ('"') and backslash 669 ('\') (the Unicode characters with code points U+0021, U+0023 through 670 U+005B, and U+005D through U+007E), or 672 (b) if new metadata members or values are defined that use other code 673 points, require that their definitions specify the exact Unicode code 674 point sequences used to represent them. Furthermore, proposed 675 registrations that use Unicode code points that can only be 676 represented in JSON strings as escaped characters must not be 677 accepted. 679 7.1.1. Registration Template 681 Metadata Name: 682 The name requested (e.g., "issuer"). This name is case-sensitive. 683 Names may not match other registered names in a case-insensitive 684 manner (one that would cause a match if the Unicode toLowerCase() 685 operation were applied to both strings) unless the Designated 686 Experts state that there is a compelling reason to allow an 687 exception. 689 Metadata Description: 690 Brief description of the metadata (e.g., "Issuer identifier URL"). 692 Change Controller: 693 For Standards Track RFCs, list the "IESG". For others, give the 694 name of the responsible party. Other details (e.g., postal 695 address, email address, home page URI) may also be included. 697 Specification Document(s): 698 Reference to the document or documents that specify the parameter, 699 preferably including URIs that can be used to retrieve copies of 700 the documents. An indication of the relevant sections may also be 701 included but is not required. 703 7.1.2. Initial Registry Contents 705 o Metadata Name: "issuer" 706 o Metadata Description: Authorization server's issuer identifier URL 707 o Change Controller: IESG 708 o Specification Document(s): Section 2 of [[ this specification ]] 710 o Metadata Name: "authorization_endpoint" 711 o Metadata Description: URL of the authorization server's 712 authorization endpoint 713 o Change Controller: IESG 714 o Specification Document(s): Section 2 of [[ this specification ]] 716 o Metadata Name: "token_endpoint" 717 o Metadata Description: URL of the authorization server's token 718 endpoint 719 o Change Controller: IESG 720 o Specification Document(s): Section 2 of [[ this specification ]] 722 o Metadata Name: "jwks_uri" 723 o Metadata Description: URL of the authorization server's JWK Set 724 document 725 o Change Controller: IESG 726 o Specification Document(s): Section 2 of [[ this specification ]] 728 o Metadata Name: "registration_endpoint" 729 o Metadata Description: URL of the authorization server's OAuth 2.0 730 Dynamic Client Registration Endpoint 731 o Change Controller: IESG 732 o Specification Document(s): Section 2 of [[ this specification ]] 734 o Metadata Name: "scopes_supported" 735 o Metadata Description: JSON array containing a list of the OAuth 736 2.0 "scope" values that this authorization server supports 737 o Change Controller: IESG 738 o Specification Document(s): Section 2 of [[ this specification ]] 740 o Metadata Name: "response_types_supported" 741 o Metadata Description: JSON array containing a list of the OAuth 742 2.0 "response_type" values that this authorization server supports 743 o Change Controller: IESG 744 o Specification Document(s): Section 2 of [[ this specification ]] 746 o Metadata Name: "response_modes_supported" 747 o Metadata Description: JSON array containing a list of the OAuth 748 2.0 "response_mode" values that this authorization server supports 749 o Change Controller: IESG 750 o Specification Document(s): Section 2 of [[ this specification ]] 752 o Metadata Name: "grant_types_supported" 753 o Metadata Description: JSON array containing a list of the OAuth 754 2.0 grant type values that this authorization server supports 755 o Change Controller: IESG 756 o Specification Document(s): Section 2 of [[ this specification ]] 758 o Metadata Name: "token_endpoint_auth_methods_supported" 759 o Metadata Description: JSON array containing a list of client 760 authentication methods supported by this token endpoint 761 o Change Controller: IESG 762 o Specification Document(s): Section 2 of [[ this specification ]] 764 o Metadata Name: "token_endpoint_auth_signing_alg_values_supported" 765 o Metadata Description: JSON array containing a list of the JWS 766 signing algorithms supported by the token endpoint for the 767 signature on the JWT used to authenticate the client at the token 768 endpoint 769 o Change Controller: IESG 770 o Specification Document(s): Section 2 of [[ this specification ]] 772 o Metadata Name: "service_documentation" 773 o Metadata Description: URL of a page containing human-readable 774 information that developers might want or need to know when using 775 the authorization server 776 o Change Controller: IESG 777 o Specification Document(s): Section 2 of [[ this specification ]] 779 o Metadata Name: "ui_locales_supported" 780 o Metadata Description: Languages and scripts supported for the user 781 interface, represented as a JSON array of BCP47 language tag 782 values 783 o Change Controller: IESG 784 o Specification Document(s): Section 2 of [[ this specification ]] 786 o Metadata Name: "op_policy_uri" 787 o Metadata Description: URL that the authorization server provides 788 to the person registering the client to read about the 789 authorization server's requirements on how the client can use the 790 data provided by the authorization server 791 o Change Controller: IESG 792 o Specification Document(s): Section 2 of [[ this specification ]] 794 o Metadata Name: "op_tos_uri" 795 o Metadata Description: URL that the authorization server provides 796 to the person registering the client to read about the 797 authorization server's terms of service 798 o Change Controller: IESG 799 o Specification Document(s): Section 2 of [[ this specification ]] 801 o Metadata Name: "revocation_endpoint" 802 o Metadata Description: URL of the authorization server's OAuth 2.0 803 revocation endpoint 804 o Change Controller: IESG 805 o Specification Document(s): Section 2 of [[ this specification ]] 807 o Metadata Name: "revocation_endpoint_auth_methods_supported" 808 o Metadata Description: JSON array containing a list of client 809 authentication methods supported by this revocation endpoint 810 o Change Controller: IESG 811 o Specification Document(s): Section 2 of [[ this specification ]] 812 o Metadata Name: 813 "revocation_endpoint_auth_signing_alg_values_supported" 814 o Metadata Description: JSON array containing a list of the JWS 815 signing algorithms supported by the revocation endpoint for the 816 signature on the JWT used to authenticate the client at the 817 revocation endpoint 818 o Change Controller: IESG 819 o Specification Document(s): Section 2 of [[ this specification ]] 821 o Metadata Name: "introspection_endpoint" 822 o Metadata Description: URL of the authorization server's OAuth 2.0 823 introspection endpoint 824 o Change Controller: IESG 825 o Specification Document(s): Section 2 of [[ this specification ]] 827 o Metadata Name: "introspection_endpoint_auth_methods_supported" 828 o Metadata Description: JSON array containing a list of client 829 authentication methods supported by this introspection endpoint 830 o Change Controller: IESG 831 o Specification Document(s): Section 2 of [[ this specification ]] 833 o Metadata Name: 834 "introspection_endpoint_auth_signing_alg_values_supported" 835 o Metadata Description: JSON array containing a list of the JWS 836 signing algorithms supported by the introspection endpoint for the 837 signature on the JWT used to authenticate the client at the 838 introspection endpoint 839 o Change Controller: IESG 840 o Specification Document(s): Section 2 of [[ this specification ]] 842 o Metadata Name: "code_challenge_methods_supported" 843 o Metadata Description: PKCE code challenge methods supported by 844 this authorization server 845 o Change Controller: IESG 846 o Specification Document(s): Section 2 of [[ this specification ]] 848 7.2. Updated Registration Instructions 850 This specification adds to the instructions for the Designated 851 Experts of the following IANA registries, both of which are in the 852 "OAuth Parameters" registry [IANA.OAuth.Parameters]: 854 o OAuth Access Token Types 855 o OAuth Token Endpoint Authentication Methods 857 IANA has added a link to this specification in the Reference sections 858 of these registries. [[ RFC Editor: The above sentence is written in 859 the past tense as it would appear in the final specification, even 860 though these links won't actually be created until after the IESG has 861 requested publication of the specification. Please delete this note 862 after the links are in place. ]] 864 For these registries, the designated experts must reject registration 865 requests in one registry for values already occurring in the other 866 registry. This is necessary because the 867 "introspection_endpoint_auth_methods_supported" parameter allows for 868 the use of values from either registry. That way, because the values 869 in the two registries will continue to be mutually exclusive, no 870 ambiguities will arise. 872 7.3. Well-Known URI Registry 874 This specification registers the well-known URI defined in Section 3 875 in the IANA "Well-Known URIs" registry [IANA.well-known] established 876 by RFC 5785 [RFC5785]. 878 7.3.1. Registry Contents 880 o URI suffix: "oauth-authorization-server" 881 o Change controller: IESG 882 o Specification document: Section 3 of [[ this specification ]] 883 o Related information: (none) 885 8. References 887 8.1. Normative References 889 [BCP195] Sheffer, Y., Holz, R., and P. Saint-Andre, 890 "Recommendations for Secure Use of Transport Layer 891 Security (TLS) and Datagram Transport Layer Security 892 (DTLS)", BCP 195, RFC 7525, DOI 10.17487/RFC7525, May 893 2015, . 895 [IANA.OAuth.Parameters] 896 IANA, "OAuth Parameters", 897 . 899 [JWE] Jones, M. and J. Hildebrand, "JSON Web Encryption (JWE)", 900 RFC 7516, DOI 10.17487/RFC7516, May 2015, 901 . 903 [JWK] Jones, M., "JSON Web Key (JWK)", RFC 7517, 904 DOI 10.17487/RFC7517, May 2015, 905 . 907 [JWS] Jones, M., Bradley, J., and N. Sakimura, "JSON Web 908 Signature (JWS)", RFC 7515, DOI 10.17487/RFC7515, May 909 2015, . 911 [JWT] Jones, M., Bradley, J., and N. Sakimura, "JSON Web Token 912 (JWT)", RFC 7519, DOI 10.17487/RFC7519, May 2015, 913 . 915 [OAuth.Post] 916 Jones, M. and B. Campbell, "OAuth 2.0 Form Post Response 917 Mode", April 2015, . 920 [OAuth.Responses] 921 de Medeiros, B., Ed., Scurtescu, M., Tarjan, P., and M. 922 Jones, "OAuth 2.0 Multiple Response Type Encoding 923 Practices", February 2014, . 926 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 927 Requirement Levels", BCP 14, RFC 2119, 928 DOI 10.17487/RFC2119, March 1997, 929 . 931 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 932 (TLS) Protocol Version 1.2", RFC 5246, 933 DOI 10.17487/RFC5246, August 2008, 934 . 936 [RFC5646] Phillips, A., Ed. and M. Davis, Ed., "Tags for Identifying 937 Languages", BCP 47, RFC 5646, DOI 10.17487/RFC5646, 938 September 2009, . 940 [RFC5785] Nottingham, M. and E. Hammer-Lahav, "Defining Well-Known 941 Uniform Resource Identifiers (URIs)", RFC 5785, 942 DOI 10.17487/RFC5785, April 2010, 943 . 945 [RFC6125] Saint-Andre, P. and J. Hodges, "Representation and 946 Verification of Domain-Based Application Service Identity 947 within Internet Public Key Infrastructure Using X.509 948 (PKIX) Certificates in the Context of Transport Layer 949 Security (TLS)", RFC 6125, DOI 10.17487/RFC6125, March 950 2011, . 952 [RFC6749] Hardt, D., Ed., "The OAuth 2.0 Authorization Framework", 953 RFC 6749, DOI 10.17487/RFC6749, October 2012, 954 . 956 [RFC7009] Lodderstedt, T., Ed., Dronia, S., and M. Scurtescu, "OAuth 957 2.0 Token Revocation", RFC 7009, DOI 10.17487/RFC7009, 958 August 2013, . 960 [RFC7033] Jones, P., Salgueiro, G., Jones, M., and J. Smarr, 961 "WebFinger", RFC 7033, DOI 10.17487/RFC7033, September 962 2013, . 964 [RFC7159] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data 965 Interchange Format", RFC 7159, DOI 10.17487/RFC7159, March 966 2014, . 968 [RFC7591] Richer, J., Ed., Jones, M., Bradley, J., Machulak, M., and 969 P. Hunt, "OAuth 2.0 Dynamic Client Registration Protocol", 970 RFC 7591, DOI 10.17487/RFC7591, July 2015, 971 . 973 [RFC7636] Sakimura, N., Ed., Bradley, J., and N. Agarwal, "Proof Key 974 for Code Exchange by OAuth Public Clients", RFC 7636, 975 DOI 10.17487/RFC7636, September 2015, 976 . 978 [RFC7662] Richer, J., Ed., "OAuth 2.0 Token Introspection", 979 RFC 7662, DOI 10.17487/RFC7662, October 2015, 980 . 982 [RFC8126] Cotton, M., Leiba, B., and T. Narten, "Guidelines for 983 Writing an IANA Considerations Section in RFCs", BCP 26, 984 RFC 8126, DOI 10.17487/RFC8126, June 2017, 985 . 987 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 988 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 989 May 2017, . 991 [UNICODE] The Unicode Consortium, "The Unicode Standard", 992 . 994 [USA15] Davis, M. and K. Whistler, "Unicode Normalization Forms", 995 Unicode Standard Annex 15, June 2015, 996 . 998 8.2. Informative References 1000 [I-D.ietf-oauth-mix-up-mitigation] 1001 Jones, M., Bradley, J., and N. Sakimura, "OAuth 2.0 Mix-Up 1002 Mitigation", draft-ietf-oauth-mix-up-mitigation-01 (work 1003 in progress), July 2016. 1005 [IANA.well-known] 1006 IANA, "Well-Known URIs", 1007 . 1009 [OpenID.Core] 1010 Sakimura, N., Bradley, J., Jones, M., de Medeiros, B., and 1011 C. Mortimore, "OpenID Connect Core 1.0", November 2014, 1012 . 1014 [OpenID.Discovery] 1015 Sakimura, N., Bradley, J., Jones, M., and E. Jay, "OpenID 1016 Connect Discovery 1.0", November 2014, 1017 . 1020 [OpenID.Registration] 1021 Sakimura, N., Bradley, J., and M. Jones, "OpenID Connect 1022 Dynamic Client Registration 1.0", November 2014, 1023 . 1026 Appendix A. Acknowledgements 1028 This specification is based on the OpenID Connect Discovery 1.0 1029 specification, which was produced by the OpenID Connect working group 1030 of the OpenID Foundation. This specification standardizes the de 1031 facto usage of the metadata format defined by OpenID Connect 1032 Discovery to publish OAuth authorization server metadata. 1034 The authors would like to thank the following people for their 1035 reviews of this specification: Shwetha Bhandari, Ben Campbell, Brian 1036 Campbell, Brian Carpenter, William Denniss, Vladimir Dzhuvinov, 1037 Donald Eastlake, Samuel Erdtman, George Fletcher, Dick Hardt, Phil 1038 Hunt, Alexey Melnikov, Tony Nadalin, Mark Nottingham, Eric Rescorla, 1039 Justin Richer, Adam Roach, Hannes Tschofenig, and Hans Zandbelt. 1041 Appendix B. Document History 1043 [[ to be removed by the RFC Editor before publication as an RFC ]] 1045 -10 1047 o Clarified the meaning of "case-insensitive", as suggested by 1048 Alexey Melnikov. 1050 -09 1051 o Revised the transformation between the issuer identifier and the 1052 authorization server metadata location to conform to BCP 190, as 1053 suggested by Adam Roach. 1055 o Defined the characters allowed in registered metadata names and 1056 values, as suggested by Alexey Melnikov. 1058 o Changed to using the RFC 8174 boilerplate instead of the RFC 2119 1059 boilerplate, as suggested by Ben Campbell. 1061 o Acknowledged additional reviewers. 1063 -08 1065 o Changed the "authorization_endpoint" to be REQUIRED only when 1066 grant types are supported that use the authorization endpoint. 1068 o Added the statement, to provide historical context, that this 1069 specification standardizes the de facto usage of the metadata 1070 format defined by OpenID Connect Discovery to publish OAuth 1071 authorization server metadata. 1073 o Applied clarifications suggested by Mark Nottingham about when 1074 application-specific well-known suffixes are and are not 1075 appropriate. 1077 o Acknowledged additional reviewers. 1079 -07 1081 o Applied clarifications suggested by EKR. 1083 -06 1085 o Incorporated resolutions to working group last call comments. 1087 -05 1089 o Removed the "protected_resources" element and the reference to 1090 draft-jones-oauth-resource-metadata. 1092 -04 1094 o Added the ability to list protected resources with the 1095 "protected_resources" element. 1097 o Added ability to provide signed metadata with the 1098 "signed_metadata" element. 1100 o Removed "Discovery" from the name, since this is now just about 1101 authorization server metadata. 1103 -03 1105 o Changed term "issuer URL" to "issuer identifier" for terminology 1106 consistency, paralleling the same terminology consistency change 1107 in the mix-up mitigation spec. 1109 -02 1111 o Changed the title to OAuth 2.0 Authorization Server Discovery 1112 Metadata. 1114 o Made "jwks_uri" and "registration_endpoint" OPTIONAL. 1116 o Defined the well-known URI string "/.well-known/oauth- 1117 authorization-server". 1119 o Added security considerations about publishing authorization 1120 server discovery metadata in a standard format. 1122 o Added security considerations about protected resources. 1124 o Added more information to the "grant_types_supported" and 1125 "response_types_supported" definitions. 1127 o Referenced the working group Mix-Up Mitigation draft. 1129 o Changed some example metadata values. 1131 o Acknowledged individuals for their contributions to the 1132 specification. 1134 -01 1136 o Removed WebFinger discovery. 1138 o Clarified the relationship between the issuer identifier URL and 1139 the well-known URI path relative to it at which the discovery 1140 metadata document is located. 1142 -00 1144 o Created the initial working group version based on draft-jones- 1145 oauth-discovery-01, with no normative changes. 1147 Authors' Addresses 1149 Michael B. Jones 1150 Microsoft 1152 Email: mbj@microsoft.com 1153 URI: http://self-issued.info/ 1155 Nat Sakimura 1156 Nomura Research Institute, Ltd. 1158 Email: n-sakimura@nri.co.jp 1159 URI: http://nat.sakimura.org/ 1161 John Bradley 1162 Ping Identity 1164 Email: ve7jtb@ve7jtb.com 1165 URI: http://www.thread-safe.com/