public enum ClientAuthMethod extends Enum<ClientAuthMethod>
| Enum Constant and Description |
|---|
CLIENT_SECRET_BASIC
"client_secret_basic" (1). |
CLIENT_SECRET_JWT
"client_secret_jwt" (3). |
CLIENT_SECRET_POST
"client_secret_post" (2). |
NONE
"none" (0). |
PRIVATE_KEY_JWT
"private_key_jwt" (4). |
SELF_SIGNED_TLS_CLIENT_AUTH
"self_signed_tls_client_auth" (6). |
TLS_CLIENT_AUTH
"tls_client_auth" (5). |
| Modifier and Type | Method and Description |
|---|---|
static ClientAuthMethod |
getByValue(short value)
Find an instance of this enum by a value.
|
short |
getValue()
Get the integer representation of this enum instance.
|
boolean |
isCertificateBased()
Check if this instance represents a certificate-based client
authentication method.
|
boolean |
isJwtBased()
Check if this instance represents a JWT-based client authentication
method.
|
boolean |
isSecretBased()
Check if this instance represents a client-secret-based client
authentication method.
|
static ClientAuthMethod |
parse(String method)
Convert
String to ClientAuthMethod. |
static ClientAuthMethod[] |
toArray(int bits) |
static int |
toBits(EnumSet<ClientAuthMethod> set) |
static EnumSet<ClientAuthMethod> |
toSet(ClientAuthMethod[] array) |
static EnumSet<ClientAuthMethod> |
toSet(int bits) |
String |
toString() |
static ClientAuthMethod |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ClientAuthMethod[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ClientAuthMethod NONE
"none" (0).
The Client does not authenticate itself at the Token Endpoint, either because it uses only the Implicit Flow (and so does not use the Token Endpoint) or because it is a Public Client with no Client Secret or other authentication mechanism.
public static final ClientAuthMethod CLIENT_SECRET_BASIC
"client_secret_basic" (1).
Clients that have received a client_secret value from
the Authorization Server authenticate with the Authorization
Server in accordance with
Section 3.2.1 of OAuth 2.0
[RFC6749]
using the HTTP Basic authentication scheme.
public static final ClientAuthMethod CLIENT_SECRET_POST
"client_secret_post" (2).
Clients that have received a client_secret value from
the Authorization Server, authenticate with the Authorization
Server in accordance with
Section 3.2.1 of OAuth 2.0
[RFC6749]
by including the Client Credentials in the request body.
public static final ClientAuthMethod CLIENT_SECRET_JWT
"client_secret_jwt" (3).
Clients that have received a client_secret value from
the Authorization Server create a JWT using an HMAC SHA
algorithm, such as HMAC SHA-256. The HMAC (Hash-based Message
Authentication Code) is calculated using the octets of the
UTF-8 representation of the client_secret as the
shared key.
The Client authenticates in accordance with JSON Web Token (JWT) Profile for OAuth 2.0 Client Authentication and Authorization Grants [OAuth.JWT] and Assertion Framework for OAuth 2.0 Client Authentication and Authorization Grants [OAuth.Assertions].
public static final ClientAuthMethod PRIVATE_KEY_JWT
"private_key_jwt" (4).
Clients that have registered a public key sign a JWT using that key. The Client authenticates in accordance with JSON Web Token (JWT) Profile for OAuth 2.0 Client Authentication and Authorization Grants [OAuth.JWT] and Assertion Framework for OAuth 2.0 Client Authentication and Authorization Grants [OAuth.Assertions].
public static final ClientAuthMethod TLS_CLIENT_AUTH
"tls_client_auth" (5).
Clients authenticate with the Authorization Server using X.509 certificates as defined in "Mutual TLS Profiles for OAuth Clients".
public static final ClientAuthMethod SELF_SIGNED_TLS_CLIENT_AUTH
"self_signed_tls_client_auth" (6).
Clients authenticate with the Authorization Server using self-signed certificates as defined in "Mutual TLS Profiles for OAuth Clients".
public static ClientAuthMethod[] values()
for (ClientAuthMethod c : ClientAuthMethod.values()) System.out.println(c);
public static ClientAuthMethod valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic short getValue()
public String toString()
toString in class Enum<ClientAuthMethod>public static ClientAuthMethod getByValue(short value)
value - The integer representation of the instance to find.null if not found.public static ClientAuthMethod parse(String method)
String to ClientAuthMethod.method - Client authentication method. For example,
"client_secret_basic".ClientAuthMethod instance, or null.public static int toBits(EnumSet<ClientAuthMethod> set)
public static ClientAuthMethod[] toArray(int bits)
public static EnumSet<ClientAuthMethod> toSet(int bits)
public static EnumSet<ClientAuthMethod> toSet(ClientAuthMethod[] array)
public boolean isSecretBased()
true if this instance is either
CLIENT_SECRET_BASIC or
CLIENT_SECRET_POST.public boolean isJwtBased()
true if this instance is either
CLIENT_SECRET_JWT or
PRIVATE_KEY_JWT.public boolean isCertificateBased()
true if this instance is either
TLS_CLIENT_AUTH or
SELF_SIGNED_TLS_CLIENT_AUTH.Copyright © 2019. All rights reserved.