Class AbstractOpenSslFeedbackCipher
java.lang.Object
org.apache.commons.crypto.cipher.AbstractOpenSslFeedbackCipher
- Direct Known Subclasses:
OpenSslCommonMode, OpenSslGaloisCounterMode
This class represents a block cipher in one of its modes.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final intprotected intprotected longprotected final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidclean()(package private) abstract intdoFinal(byte[] input, int inputOffset, int inputLen, byte[] output, int outputOffset) (package private) abstract intdoFinal(ByteBuffer input, ByteBuffer output) (package private) abstract voidinit(int mode, byte[] key, AlgorithmParameterSpec params) (package private) abstract intupdate(byte[] input, int inputOffset, int inputLen, byte[] output, int outputOffset) (package private) abstract intupdate(ByteBuffer input, ByteBuffer output) (package private) abstract voidupdateAAD(byte[] aad)
-
Field Details
-
context
protected long context -
algorithmMode
protected final int algorithmMode -
padding
protected final int padding -
cipherMode
protected int cipherMode
-
-
Constructor Details
-
AbstractOpenSslFeedbackCipher
AbstractOpenSslFeedbackCipher(long context, int algorithmMode, int padding)
-
-
Method Details
-
checkState
public void checkState() -
clean
public void clean() -
doFinal
abstract int doFinal(byte[] input, int inputOffset, int inputLen, byte[] output, int outputOffset) throws ShortBufferException, IllegalBlockSizeException, BadPaddingException -
doFinal
abstract int doFinal(ByteBuffer input, ByteBuffer output) throws ShortBufferException, IllegalBlockSizeException, BadPaddingException -
init
abstract void init(int mode, byte[] key, AlgorithmParameterSpec params) throws InvalidAlgorithmParameterException -
update
abstract int update(byte[] input, int inputOffset, int inputLen, byte[] output, int outputOffset) throws ShortBufferException - Throws:
ShortBufferException
-
update
- Throws:
ShortBufferException
-
updateAAD
abstract void updateAAD(byte[] aad)
-