Package org.forgerock.json.jose.jws
Enum JwsAlgorithmType
- java.lang.Object
-
- java.lang.Enum<JwsAlgorithmType>
-
- org.forgerock.json.jose.jws.JwsAlgorithmType
-
- All Implemented Interfaces:
Serializable
,Comparable<JwsAlgorithmType>
public enum JwsAlgorithmType extends Enum<JwsAlgorithmType>
An Enum of the possible types of JWS algorithms that can be used to sign a JWT.- Since:
- 2.0.0
- See Also:
JwsAlgorithm
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
toString()
Turns the JwsAlgorithmType constant into a JSON value string.static JwsAlgorithmType
valueOf(String name)
Returns the enum constant of this type with the specified name.static JwsAlgorithmType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NONE
@Deprecated public static final JwsAlgorithmType NONE
Deprecated.This algorithm is inherently insecure and shouldn't be used.No digital signature or MAC value included.
-
HMAC
public static final JwsAlgorithmType HMAC
HMAC signing algorithm.
-
RSA
public static final JwsAlgorithmType RSA
RSA signing algorithm.
-
ECDSA
public static final JwsAlgorithmType ECDSA
Elliptic Curve DSA signing algorithm.
-
EDDSA
public static final JwsAlgorithmType EDDSA
Edwards Curve DSA signing algorithm. See RFC 8037.
-
-
Method Detail
-
values
public static JwsAlgorithmType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (JwsAlgorithmType c : JwsAlgorithmType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static JwsAlgorithmType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
toString
public String toString()
Turns the JwsAlgorithmType constant into a JSON value string.- Overrides:
toString
in classEnum<JwsAlgorithmType>
- Returns:
-
-