- All Implemented Interfaces:
Serializable, Comparable<EstablishBase.State>, java.lang.constant.Constable
- Enclosing class:
EstablishBase
States for NTCP connection establishment process. Tracks the progression through various phases of the handshake.
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E>Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionHandshake data failed verification.Inbound handshake, waiting for the initiator's key.Got Noise part of msg 1 Next state IB_NTCP2_GOT_PADDING or IB_NTCP2_READ_RANDOM on fail.Got msg 1 incl.Got msg 3 Next state VERIFIED.Got X part of msg 1 Next state IB_NTCP2_GOT_MSG1 or IB_NTCP2_READ_RANDOM on fail.Next state IB_NTCP2_GOT_X.Got msg 1 and failed AEAD Next state CORRUPT.Sent msg 2 and padding Next state IB_NTCP2_GOT_RI.Outbound handshake, waiting for the responder's key.OB: got and verified 4; IB: got and verified 3 and sent 4.Constructor Summary
ConstructorsMethod Summary
All MethodsModifier and TypeMethodDescriptionstatic EstablishBase.StateReturns the enum constant of this class with the specified name.static EstablishBase.State[]values()Returns an array containing the constants of this enum class, in the order they are declared.
Enum Constant Details
OB_INIT
Outbound handshake, waiting for the responder's key.IB_INIT
Inbound handshake, waiting for the initiator's key.IB_NTCP2_INIT
Next state IB_NTCP2_GOT_X.IB_NTCP2_GOT_X
Got X part of msg 1 Next state IB_NTCP2_GOT_MSG1 or IB_NTCP2_READ_RANDOM on fail.IB_NTCP2_GOT_MSG1
Got Noise part of msg 1 Next state IB_NTCP2_GOT_PADDING or IB_NTCP2_READ_RANDOM on fail.IB_NTCP2_GOT_PADDING
Got msg 1 incl. padding Next state IB_NTCP2_SENT_Y.IB_NTCP2_SENT_Y
Sent msg 2 and padding Next state IB_NTCP2_GOT_RI.IB_NTCP2_GOT_RI
Got msg 3 Next state VERIFIED.IB_NTCP2_READ_RANDOM
Got msg 1 and failed AEAD Next state CORRUPT.VERIFIED
OB: got and verified 4; IB: got and verified 3 and sent 4.CORRUPT
Handshake data failed verification.
Constructor Details
State
private State()
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