Package com.yubico.yubikit.piv
Enum Class PinPolicy
- All Implemented Interfaces:
Serializable
,Comparable<PinPolicy>
,Constable
The PIN policy of a private key defines whether or not a PIN is required to use the key.
Setting a PIN policy other than DEFAULT requires YubiKey 4 or later.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe PIN must be verified each time the key is to be used, just prior to using it.The default behavior for the particular key slot is used.PIN or biometrics must be verified each time the key is to be used, just prior to using it.PIN or biometrics must be verified for the session, prior to using the key.The PIN is never required for using the key.The PIN must be verified for the session, prior to using the key. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic PinPolicy
fromValue
(int value) Returns the PIN policy corresponding to the given PIV application constant.static PinPolicy
Returns the enum constant of this class with the specified name.static PinPolicy[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
DEFAULT
The default behavior for the particular key slot is used. -
NEVER
The PIN is never required for using the key. -
ONCE
The PIN must be verified for the session, prior to using the key. -
ALWAYS
The PIN must be verified each time the key is to be used, just prior to using it. -
MATCH_ONCE
PIN or biometrics must be verified for the session, prior to using the key. -
MATCH_ALWAYS
PIN or biometrics must be verified each time the key is to be used, just prior to using it.
-
-
Field Details
-
value
public final int value
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException
- if the argument is null
-
fromValue
Returns the PIN policy corresponding to the given PIV application constant.
-