Class GordianStreamCipherSpec
java.lang.Object
io.github.tonywasher.joceanus.gordianknot.api.cipher.GordianCipherSpec<GordianStreamKeySpec>
io.github.tonywasher.joceanus.gordianknot.api.cipher.GordianStreamCipherSpec
- All Implemented Interfaces:
GordianIdSpec
public final class GordianStreamCipherSpec
extends GordianCipherSpec<GordianStreamKeySpec>
implements GordianIdSpec
The StreamCipherSpec class.
-
Constructor Summary
ConstructorsConstructorDescriptionGordianStreamCipherSpec(GordianStreamKeySpec pKeySpec) Constructor.GordianStreamCipherSpec(GordianStreamKeySpec pKeySpec, boolean pAEAD) Constructor. -
Method Summary
Methods inherited from class io.github.tonywasher.joceanus.gordianknot.api.cipher.GordianCipherSpec
getKeyType
-
Constructor Details
-
GordianStreamCipherSpec
Constructor.- Parameters:
pKeySpec- the keySpec
-
GordianStreamCipherSpec
Constructor.- Parameters:
pKeySpec- the keySpecpAEAD- is this an AAD cipher?
-
-
Method Details
-
needsIV
public boolean needsIV()Description copied from class:GordianCipherSpecObtain the cipherMode.- Specified by:
needsIVin classGordianCipherSpec<GordianStreamKeySpec>- Returns:
- the mode
-
getIVLength
public int getIVLength()Description copied from class:GordianCipherSpecObtain the IV length for the cipher.- Specified by:
getIVLengthin classGordianCipherSpec<GordianStreamKeySpec>- Returns:
- the IV length
-
isAEADMode
public boolean isAEADMode()Is the keySpec an AEAD cipher mode?- Returns:
- true/false.
-
isAEAD
public boolean isAEAD()Is the keySpec an AEAD cipher?- Returns:
- true/false.
-
isValid
public boolean isValid()Description copied from class:GordianCipherSpecIs the keySpec valid?- Specified by:
isValidin classGordianCipherSpec<GordianStreamKeySpec>- Returns:
- true/false.
-
toString
- Overrides:
toStringin classGordianCipherSpec<GordianStreamKeySpec>
-
equals
- Overrides:
equalsin classGordianCipherSpec<GordianStreamKeySpec>
-
hashCode
public int hashCode()- Overrides:
hashCodein classGordianCipherSpec<GordianStreamKeySpec>
-