Top Description Fields Constructors Methods
com.oracle.bmc.auth.internal

public final Class JWK

extends Object
Class Inheritance
Imports
jakarta.annotation.Nonnull, .Nullable, com.fasterxml.jackson.annotation.JsonCreator, .JsonInclude, .JsonProperty, com.oracle.bmc.util.internal.Validate

Representation of a RSA public key in JSON Web Key (JWK) format.
See Also
JSON Web Key Specification

Class is immutable. @Immutable

Field Summary

Modifier and TypeField and Description
private static final String
private final String
private final String
e

private static final String
private final String
private final String
n

private static final String
private final String

Constructor Summary

AccessConstructor and Description
public
JWK(String kid, String n, String e)

public
JWK(String kid, String n, String e, String type, String algorithm, String use)

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

the alg (Algorithm} for this key. Optional.
getAlgorithm
()

public String

Returns:

the kid (key ID) for this key. Case sensitive. Optional in spec, required in OPC.
getKeyId
()

public String

Returns:

the kty (Key Type) for this key. Case sensitive, required.
getKeyType
()

public String

Returns:

the RSA modulus for this key. Required.
getModulus
()

base64url encoded

public String

Returns:

the RSA public exponent for this key. Required.
getPublicExponent
()

base64url encoded

public String

Returns:

the use (Public Key use) for this key. Optional.
getPublicKeyUse
()

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

ALGORITHMback to summary
private static final String ALGORITHM
algorithmback to summary
private final String algorithm
Annotations
@JsonInclude:NON_NULL
eback to summary
private final String e
KEY_TYPEback to summary
private static final String KEY_TYPE
kidback to summary
private final String kid
nback to summary
private final String n
USEback to summary
private static final String USE
useback to summary
private final String use
Annotations
@JsonInclude:NON_NULL

Constructor Detail

JWKback to summary
public JWK(String kid, String n, String e)
JWKback to summary
public JWK(String kid, String n, String e, String type, String algorithm, String use)
Annotations
@JsonCreator

Method Detail

getAlgorithmback to summary
public String getAlgorithm()
Returns:String

the alg (Algorithm} for this key. Optional.

Annotations
@JsonProperty:alg
See Also
Algorithm
getKeyIdback to summary
public String getKeyId()
Returns:String

the kid (key ID) for this key. Case sensitive. Optional in spec, required in OPC.

Annotations
@JsonProperty:kid
See Also
Key ID
getKeyTypeback to summary
public String getKeyType()
Returns:String

the kty (Key Type) for this key. Case sensitive, required.

Annotations
@JsonProperty:kty
See Also
Key Type
getModulusback to summary
public String getModulus()

base64url encoded

Returns:String

the RSA modulus for this key. Required.

Annotations
@JsonProperty:n
getPublicExponentback to summary
public String getPublicExponent()

base64url encoded

Returns:String

the RSA public exponent for this key. Required.

Annotations
@JsonProperty:e
getPublicKeyUseback to summary
public String getPublicKeyUse()
Returns:String

the use (Public Key use) for this key. Optional.

Annotations
@JsonProperty:use
See Also
Public Key use