OAuth2AuthorizationServerMetadata

@Serializable
data class OAuth2AuthorizationServerMetadata(val issuer: String, val authorizationEndpoint: String? = null, val pushedAuthorizationRequestEndpoint: String? = null, val requirePushedAuthorizationRequests: Boolean? = null, val tokenEndpoint: String? = null, val jsonWebKeySetUrl: String? = null, val registrationEndpoint: String? = null, val scopesSupported: Set<String>? = null, val responseTypesSupported: Set<String>? = null, val responseModesSupported: Set<String>? = null, val grantTypesSupported: Set<String>? = null, val tokenEndPointAuthMethodsSupported: Set<String>? = null, val tokenEndPointAuthSigningAlgValuesSupported: Set<String>? = null, val subjectTypesSupported: Set<String>? = null, val idTokenSigningAlgorithmsSupportedStrings: Set<String>? = null, val requestObjectSigningAlgorithmsSupportedStrings: Set<String>? = null, val subjectSyntaxTypesSupported: Set<String>? = null, val idTokenTypesSupported: Set<IdTokenType>? = null, val presentationDefinitionUriSupported: Boolean = true, val vpFormatsSupported: VpFormatsSupported? = null, val clientIdSchemesSupported: Set<String>? = null, val dpopSigningAlgValuesSupportedStrings: Set<String>? = null, val serviceDocumentation: String? = null, val uiLocalesSupported: Set<String>? = null, val opPolicyUri: String? = null, val opTosUri: String? = null, val revocationEndpoint: String? = null, val revocationEndpointAuthMethodsSupported: Set<String>? = null, val revocationEndpointAuthSigningAlgValuesSupported: Set<String>? = null, val introspectionEndpoint: String? = null, val introspectionEndpointAuthMethodsSupported: Set<String>? = null, val introspectionEndpointAuthSigningAlgValuesSupported: Set<String>? = null, val codeChallengeMethodsSupported: Set<String>? = null)(source)

This implements RFC8414 All descriptions taken from section 2.

To be serialized into /.well-known/oauth-authorization-server which is the registered default-path, see IANA

Constructors

Link copied to clipboard
constructor(issuer: String, authorizationEndpoint: String? = null, pushedAuthorizationRequestEndpoint: String? = null, requirePushedAuthorizationRequests: Boolean? = null, tokenEndpoint: String? = null, jsonWebKeySetUrl: String? = null, registrationEndpoint: String? = null, scopesSupported: Set<String>? = null, responseTypesSupported: Set<String>? = null, responseModesSupported: Set<String>? = null, grantTypesSupported: Set<String>? = null, tokenEndPointAuthMethodsSupported: Set<String>? = null, tokenEndPointAuthSigningAlgValuesSupported: Set<String>? = null, subjectTypesSupported: Set<String>? = null, idTokenSigningAlgorithmsSupportedStrings: Set<String>? = null, requestObjectSigningAlgorithmsSupportedStrings: Set<String>? = null, subjectSyntaxTypesSupported: Set<String>? = null, idTokenTypesSupported: Set<IdTokenType>? = null, presentationDefinitionUriSupported: Boolean = true, vpFormatsSupported: VpFormatsSupported? = null, clientIdSchemesSupported: Set<String>? = null, dpopSigningAlgValuesSupportedStrings: Set<String>? = null, serviceDocumentation: String? = null, uiLocalesSupported: Set<String>? = null, opPolicyUri: String? = null, opTosUri: String? = null, revocationEndpoint: String? = null, revocationEndpointAuthMethodsSupported: Set<String>? = null, revocationEndpointAuthSigningAlgValuesSupported: Set<String>? = null, introspectionEndpoint: String? = null, introspectionEndpointAuthMethodsSupported: Set<String>? = null, introspectionEndpointAuthSigningAlgValuesSupported: Set<String>? = null, codeChallengeMethodsSupported: Set<String>? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
@SerialName(value = "authorization_endpoint")
val authorizationEndpoint: String? = null

URL of the authorization server's authorization endpoint RFC6749. This is REQUIRED unless no grant types are supported that use the authorization endpoint.

Link copied to clipboard
@SerialName(value = "client_id_schemes_supported")
val clientIdSchemesSupported: Set<String>? = null

OID4VP: OPTIONAL. Array of JSON Strings containing the values of the Client Identifier schemes that the Wallet supports. The values defined by this specification are pre-registered, redirect_uri, entity_id, did. If omitted, the default value is pre-registered.

Link copied to clipboard
@SerialName(value = "code_challenge_methods_supported")
val codeChallengeMethodsSupported: Set<String>? = null

OPTIONAL. JSON array containing a list of Proof Key for Code Exchange (PKCE) RFC7636 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 RFC7636. The valid code challenge method values are those registered in the IANA "PKCE Code Challenge Methods" registry IANA.OAuth.Parameters. If omitted, the authorization server does not support PKCE.

Link copied to clipboard
@Transient
val dpopSigningAlgValuesSupported: Set<JsonWebAlgorithm>?

RFC 9449: A JSON array containing a list of the JWS alg values (from the IANA.JOSE.ALGS registry) supported by the authorization server for DPoP proof JWTs.

Link copied to clipboard
@SerialName(value = "dpop_signing_alg_values_supported")
val dpopSigningAlgValuesSupportedStrings: Set<String>? = null

RFC 9449: A JSON array containing a list of the JWS alg values (from the IANA.JOSE.ALGS registry) supported by the authorization server for DPoP proof JWTs.

Link copied to clipboard
@SerialName(value = "grant_types_supported")
val grantTypesSupported: Set<String>? = null

OPTIONAL. JSON array containing a list of the OAuth 2.0 grant type values that this authorization server supports. The array values used are the same as those used with the "grant_types" parameter defined by "OAuth 2.0 Dynamic Client Registration Protocol" RFC7591. If omitted, the default value is ""authorization_code", "implicit"".

Link copied to clipboard
@Transient
val idTokenSigningAlgorithmsSupported: Set<JwsAlgorithm>?

OIDC Discovery: REQUIRED. A JSON array containing a list of the JWS signing algorithms (alg values) supported by the OP for the ID Token to encode the Claims in a JWT (RFC7519). Valid values include RS256, ES256, ES256K, and EdDSA.

Link copied to clipboard
@SerialName(value = "id_token_signing_alg_values_supported")
val idTokenSigningAlgorithmsSupportedStrings: Set<String>? = null

OIDC Discovery: REQUIRED. A JSON array containing a list of the JWS signing algorithms (alg values) supported by the OP for the ID Token to encode the Claims in a JWT (RFC7519). Valid values include RS256, ES256, ES256K, and EdDSA.

Link copied to clipboard
@SerialName(value = "id_token_types_supported")
val idTokenTypesSupported: Set<IdTokenType>? = null

OIDC SIOPv2: OPTIONAL. A JSON array of strings containing the list of ID Token types supported by the OP, the default value is attester_signed_id_token (the id token is issued by the party operating the OP, i.e. this is the classical id token as defined in OpenID.Core), may also include subject_signed_id_token (Self-Issued ID Token, i.e. the id token is signed with key material under the end-user's control).

Link copied to clipboard
@SerialName(value = "introspection_endpoint")
val introspectionEndpoint: String? = null

OPTIONAL. URL of the authorization server's OAuth 2.0 introspection endpoint RFC7662.

@SerialName(value = "introspection_endpoint_auth_methods_supported")
val introspectionEndpointAuthMethodsSupported: Set<String>? = null

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 IANA.OAuth.Parameters or those registered in the IANA "OAuth Access Token Types" registry IANA.OAuth.Parameters. (These values are and will remain distinct, due to Section 7.2.) If omitted, the set of supported authentication methods MUST be determined by other means.

@SerialName(value = "introspection_endpoint_auth_signing_alg_values_supported")
val introspectionEndpointAuthSigningAlgValuesSupported: Set<String>? = null

OPTIONAL. JSON array containing a list of the JWS signing algorithms ("alg" values) supported by the introspection endpoint for the signature on the JWT JWT used to authenticate the client at the introspection endpoint for the "private_key_jwt" and "client_secret_jwt" authentication methods. This metadata entry MUST be present if either of these authentication methods are specified in the "introspection_endpoint_auth_methods_supported" entry. No default algorithms are implied if this entry is omitted. The value "none" MUST NOT be used.

Link copied to clipboard
@SerialName(value = "issuer")
val issuer: String

REQUIRED. The authorization server's issuer identifier, which is a URL that uses the "https" scheme and has no query or fragment components. Authorization server metadata is published at a location that is ".well-known" according to RFC5785 derived from this issuer identifier, as described in Section 3. The issuer identifier is used to prevent authorization server mix-up attacks, as described in "OAuth 2.0 Mix-Up Mitigation" MIX-UP.

Link copied to clipboard
@SerialName(value = "jwks_uri")
val jsonWebKeySetUrl: String? = null

OPTIONAL. URL of the authorization server's JWK Set JWK document. The referenced document contains the signing key(s) the client uses to validate signatures from the authorization server. This URL MUST use the "https" scheme. The JWK Set MAY also contain the server's encryption key or keys, which are used by clients 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.

Link copied to clipboard
@SerialName(value = "op_policy_uri")
val opPolicyUri: String? = null

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 Section 5, 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.

Link copied to clipboard
@SerialName(value = "op_tos_uri")
val opTosUri: String? = null

OPTIONAL. URL that the authorization server provides to the person registering the client to read about the 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 Section 5, 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.

Link copied to clipboard
@SerialName(value = "presentation_definition_uri_supported")
val presentationDefinitionUriSupported: Boolean = true

OID4VP: OPTIONAL. Boolean value specifying whether the Wallet supports the transfer of presentation_definition by reference, with true indicating support. If omitted, the default value is true.

Link copied to clipboard
@SerialName(value = "pushed_authorization_request_endpoint")
val pushedAuthorizationRequestEndpoint: String? = null

RFC 9126: The URL of the pushed authorization request endpoint at which a client can post an authorization request to exchange for a request_uri value usable at the authorization server.

Link copied to clipboard
@SerialName(value = "registration_endpoint")
val registrationEndpoint: String? = null

OPTIONAL. URL of the authorization server's OAuth 2.0 Dynamic Client Registration endpoint RFC7591.

Link copied to clipboard
@Transient
val requestObjectSigningAlgorithmsSupported: Set<JwsAlgorithm>?

OIDC SIOPv2: REQUIRED. A JSON array containing a list of the JWS signing algorithms (alg values) supported by the OP for Request Objects, which are described in Section 6.1 of OpenID.Core. Valid values include none, RS256, ES256, ES256K, and EdDSA.

@SerialName(value = "request_object_signing_alg_values_supported")
val requestObjectSigningAlgorithmsSupportedStrings: Set<String>? = null

OIDC SIOPv2: REQUIRED. A JSON array containing a list of the JWS signing algorithms (alg values) supported by the OP for Request Objects, which are described in Section 6.1 of OpenID.Core. Valid values include none, RS256, ES256, ES256K, and EdDSA.

Link copied to clipboard
@SerialName(value = "require_pushed_authorization_requests")
val requirePushedAuthorizationRequests: Boolean? = null

RFC 9126: Boolean parameter indicating whether the authorization server accepts authorization request data only via PAR. If omitted, the default value is false.

Link copied to clipboard
@SerialName(value = "response_modes_supported")
val responseModesSupported: Set<String>? = null

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" OAuth.Responses. If omitted, the default is ""query", "fragment"". The response mode value "form_post" is also defined in "OAuth 2.0 Form Post Response Mode" OAuth.Post.

Link copied to clipboard
@SerialName(value = "response_types_supported")
val responseTypesSupported: Set<String>? = null

REQUIRED. JSON array containing a list of the OAuth 2.0 "response_type" values that this authorization server supports. The array values used are the same as those used with the "response_types" parameter defined by "OAuth 2.0 Dynamic Client Registration Protocol" RFC7591.

Link copied to clipboard
@SerialName(value = "revocation_endpoint")
val revocationEndpoint: String? = null

OPTIONAL. URL of the authorization server's OAuth 2.0 revocation endpoint RFC7009.

Link copied to clipboard
@SerialName(value = "revocation_endpoint_auth_methods_supported")
val revocationEndpointAuthMethodsSupported: Set<String>? = null

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 IANA.OAuth.Parameters. If omitted, the default is "client_secret_basic" -- the HTTP Basic Authentication Scheme specified in Section 2.3.1 of OAuth 2.0 RFC6749.

@SerialName(value = "revocation_endpoint_auth_signing_alg_values_supported")
val revocationEndpointAuthSigningAlgValuesSupported: Set<String>? = null

OPTIONAL. JSON array containing a list of the JWS signing algorithms ("alg" values) supported by the revocation endpoint for the signature on the JWT JWT used to authenticate the client at the revocation endpoint for the "private_key_jwt" and "client_secret_jwt" authentication methods. This metadata entry MUST be present if either of these authentication methods are specified in the "revocation_endpoint_auth_methods_supported" entry. No default algorithms are implied if this entry is omitted. The value "none" MUST NOT be used.

Link copied to clipboard
@SerialName(value = "scopes_supported")
val scopesSupported: Set<String>? = null

RECOMMENDED. JSON array containing a list of the OAuth 2.0 RFC6749 "scope" values that this authorization server supports. Servers MAY choose not to advertise some supported scope values even when this parameter is used.

Link copied to clipboard
@SerialName(value = "service_documentation")
val serviceDocumentation: String? = null

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.

Link copied to clipboard
@SerialName(value = "subject_syntax_types_supported")
val subjectSyntaxTypesSupported: Set<String>? = null

OIDC SIOPv2: REQUIRED. A JSON array of strings representing URI scheme identifiers and optionally method names of supported Subject Syntax Types. Valid values include urn:ietf:params:oauth:jwk-thumbprint, did:example and others.

Link copied to clipboard
@SerialName(value = "subject_types_supported")
val subjectTypesSupported: Set<String>? = null

OIDC Discovery: REQUIRED. JSON array containing a list of the Subject Identifier types that this OP supports. Valid types include pairwise and public.

Link copied to clipboard
@SerialName(value = "token_endpoint")
val tokenEndpoint: String? = null

URL of the authorization server's token endpoint RFC6749. This is REQUIRED unless only the implicit grant type is supported.

Link copied to clipboard
@SerialName(value = "token_endpoint_auth_methods_supported")
val tokenEndPointAuthMethodsSupported: Set<String>? = null

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 RFC7591. If omitted, the default is "client_secret_basic" -- the HTTP Basic Authentication Scheme specified in Section 2.3.1 of OAuth 2.0 RFC6749.

@SerialName(value = "token_endpoint_auth_signing_alg_methods_supported")
val tokenEndPointAuthSigningAlgValuesSupported: Set<String>? = null

OPTIONAL. JSON array containing a list of the JWS signing algorithms ("alg" values) supported by the token endpoint for the signature on the JWT JWT used to authenticate the client at the token endpoint for the "private_key_jwt" and "client_secret_jwt" authentication methods. This metadata entry MUST be present if either of these authentication methods are specified in the "token_endpoint_auth_methods_supported" entry. No default algorithms are implied if this entry is omitted. Servers SHOULD support "RS256". The value "none" MUST NOT be used.

Link copied to clipboard
@SerialName(value = "ui_locales_supported")
val uiLocalesSupported: Set<String>? = null

OPTIONAL. Languages and scripts supported for the user interface, represented as a JSON array of language tag values from BCP 47 RFC5646. If omitted, the set of supported languages and scripts is unspecified.

Link copied to clipboard
@SerialName(value = "vp_formats_supported")
val vpFormatsSupported: VpFormatsSupported? = null

OID4VP: REQUIRED. An object containing a list of key value pairs, where the key is a string identifying a Credential format supported by the Wallet. Valid Credential format identifier values are defined in Annex E of OpenID.VCI. Other values may be used when defined in the profiles of this specification.

Functions

Link copied to clipboard