Open Authentication Protocol T. Lodderstedt, Ed. Internet-Draft YES.com AG Intended status: Standards Track V. Dzhuvinov Expires: September 16, 2018 Connect2id Ltd. March 15, 2018 JWT Response for OAuth Token Introspection draft-lodderstedt-oauth-jwt-introspection-response-00 Abstract This draft proposes an additional JSON Web Token (JWT) based response for OAuth 2.0 Token Introspection. Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." This Internet-Draft will expire on September 16, 2018. Copyright Notice Copyright (c) 2018 IETF Trust and the persons identified as the document authors. All rights reserved. This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Lodderstedt & DzhuvinovExpires September 16, 2018 [Page 1] Internet-Draft JWT Response March 2018 Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 2. JWT Response . . . . . . . . . . . . . . . . . . . . . . . . 2 3. Client Metadata . . . . . . . . . . . . . . . . . . . . . . . 3 4. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 4 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 4 6. Security Considerations . . . . . . . . . . . . . . . . . . . 4 7. Normative References . . . . . . . . . . . . . . . . . . . . 4 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 5 1. Introduction OAuth 2.0 Token Introspection [RFC7662] specifies a method for a protected resource to query an OAuth 2.0 authorization server to determine the active state and meta-information of an OAuth 2.0 token. This allows deployments to implement identifier-based access tokens in an interoperable way. The introspection endpoint as specified in OAuth 2.0 Token Introspection [RFC7662] is a plain JSON object in "application/json" format. However, there are use cases where the resource server needs evidence about the fact the AS issued the access token and is liable for its contents. An example is a resource server using verified person data to create qualified electronic signatures. In such use cases, it would be useful to return a signed JWT as introspection response. This draft extends the Token Introspection endpoint by the capability to return responses as JWTs. 2. JWT Response The introspection endpoint may respond with a JWT in "application/ jwt" format. This JWT may contain all the members describes in Section 2.2. of [RFC7662]. The following is a non-normative example response (with line breaks for display purposes only): Lodderstedt & DzhuvinovExpires September 16, 2018 [Page 2] Internet-Draft JWT Response March 2018 HTTP/1.1 200 OK Content-Type: application/jwt eyJraWQiOiIxIiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJaNU8zdXBQQzg4UXJBa ngwMGRpcyIsImF1ZCI6Imh0dHBzOlwvXC9wcm90ZWN0ZWQuZXhhbXBsZS5uZXRcL 3Jlc291cmNlIiwiZXh0ZW5zaW9uX2ZpZWxkIjoidHdlbnR5LXNldmVuIiwic2Nvc GUiOiJyZWFkIHdyaXRlIGRvbHBoaW4iLCJpc3MiOiJodHRwczpcL1wvc2VydmVyL mV4YW1wbGUuY29tXC8iLCJhY3RpdmUiOnRydWUsImV4cCI6MTQxOTM1NjIzOCwia WF0IjoxNDE5MzUwMjM4LCJjbGllbnRfaWQiOiJsMjM4ajMyM2RzLTIzaWo0Iiwid XNlcm5hbWUiOiJqZG9lIn0.HEQHf05vqVvWVnWuEjbzUnPz6JDQVR69QkxgzBNq5 kk-sK54ieg1STazXGsdFAT8nUhiiV1f_Z4HOKNnBs8TLKaFXokhA0MqNBOYI--2u nVHDqI_RPmC3p0NmP02Xmv4hzxFmTmpgjSy3vpKQDihOjhwNBh7G81JNaJqjJQTR v_1dHUPJotQjMK3k8_5FyiO2p64Y2VyxyQn1VWVlgOHlJwhj6BaGHk4Qf5F8DHQZ 1WCPg2p_-hwfINfXh1_buSjxyDRF4oe9pKy6ZB3ejh9qIMm-WrwltuU1uWMXxN6e S6tUtpKo8UCHBwLWCHmJN7KU6ZojmaISspdS23lELAlyw The example response contains the following JSON document: { "sub": "Z5O3upPC88QrAjx00dis", "aud": "https://protected.example.net/resource", "extension_field": "twenty-seven", "scope": "read write dolphin", "iss": "https://server.example.com/", "active": true, "exp": 1419356238, "iat": 1419350238, "client_id": "l238j323ds-23ij4", "username": "jdoe" } 3. Client Metadata The authorization server determines what format to use for a particular introspection response. The decision can be based on the mechanisms described in this section. The proposal is to register resource servers as clients and let them determine the response format by utilizing new parameters for dynamic client registration. The new parameters follow the pattern established by the OpenID Connect Dynamic Client registration [OpenID.Registration] specification for configuring signing and encryption algorithms for the user info endpoint. The following parameters are introduced by this specification: Lodderstedt & DzhuvinovExpires September 16, 2018 [Page 3] Internet-Draft JWT Response March 2018 introspection_response_signed_response_alg JWS [RFC7515] "alg" algorithm JWA [RFC7518] REQUIRED for signing introspection responses. If this is specified, the response will be JWT [RFC7519] serialized, and signed using JWS. The default, if omitted, is for the introspection response to return the Claims as a UTF-8 encoded JSON object using the application/ json content-type as defined in [RFC7662]. introspection_response_encrypted_response_alg JWE [RFC7516] "alg" algorithm JWA [RFC7518] REQUIRED for encrypting introspection responses. If both signing and encryption are requested, the response will be signed then encrypted, with the result being a Nested JWT, as defined in JWT [RFC7519]. The default, if omitted, is that no encryption is performed. introspection_response_encrypted_response_enc JWE [RFC7516] "enc" algorithm JWA [RFC7518] REQUIRED for encrypting introspection responses. If "introspection_response_encrypted_response_algy" is specified, the default for this value is A128CBC-HS256. When "introspection_response_encrypted_response_enc" is included, "introspection_response_encrypted_response_alg" MUST also be provided. Resource servers may register their public encryption keys using the "jwks_uri" or "jwks" metadata parameters. 4. Acknowledgements We would like to thank ... 5. IANA Considerations TBD 6. Security Considerations TBD 7. Normative References [OpenID.Registration] NRI, Ping Identity, and Microsoft, "OpenID Connect Dynamic Client Registration 1.0 incorporating errata set 1", Nov 2014, . Lodderstedt & DzhuvinovExpires September 16, 2018 [Page 4] Internet-Draft JWT Response March 2018 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, . [RFC2246] Dierks, T. and C. Allen, "The TLS Protocol Version 1.0", RFC 2246, DOI 10.17487/RFC2246, January 1999, . [RFC7515] Jones, M., Bradley, J., and N. Sakimura, "JSON Web Signature (JWS)", RFC 7515, DOI 10.17487/RFC7515, May 2015, . [RFC7516] Jones, M. and J. Hildebrand, "JSON Web Encryption (JWE)", RFC 7516, DOI 10.17487/RFC7516, May 2015, . [RFC7518] Jones, M., "JSON Web Algorithms (JWA)", RFC 7518, DOI 10.17487/RFC7518, May 2015, . [RFC7519] Jones, M., Bradley, J., and N. Sakimura, "JSON Web Token (JWT)", RFC 7519, DOI 10.17487/RFC7519, May 2015, . [RFC7591] Richer, J., Ed., Jones, M., Bradley, J., Machulak, M., and P. Hunt, "OAuth 2.0 Dynamic Client Registration Protocol", RFC 7591, DOI 10.17487/RFC7591, July 2015, . [RFC7662] Richer, J., Ed., "OAuth 2.0 Token Introspection", RFC 7662, DOI 10.17487/RFC7662, October 2015, . Authors' Addresses Torsten Lodderstedt (editor) YES.com AG Email: torsten@lodderstedt.net Vladimir Dzhuvinov Connect2id Ltd. Email: vladimir@connect2id.com Lodderstedt & DzhuvinovExpires September 16, 2018 [Page 5]