Package org.xipki.pkcs11.wrapper.params
Class SALSA20_CHACHA20_POLY1305_PARAMS
- java.lang.Object
-
- org.xipki.pkcs11.wrapper.params.CkParams
-
- org.xipki.pkcs11.wrapper.params.SALSA20_CHACHA20_POLY1305_PARAMS
-
- All Implemented Interfaces:
CkMessageParams
public class SALSA20_CHACHA20_POLY1305_PARAMS extends CkParams implements CkMessageParams
Represents the CK_SALSA20_CHACHA20_POLY1305_PARAMS.- Author:
- Lijun Liao (xipki)
-
-
Constructor Summary
Constructors Constructor Description SALSA20_CHACHA20_POLY1305_PARAMS(byte[] nonce, byte[] aad)Create a new CK_SALSA20_CHACHA20_POLY1305_PARAMS object with the given attributes.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected intgetMaxFieldLen()CK_SALSA20_CHACHA20_POLY1305_PARAMSgetParams()Get this parameters object as an object of the corresponding *_PARAMS class of the iaik.pkcs.pkcs11.wrapper package.voidsetValuesFromPKCS11Object(Object obj)Read the parameters from the PKCS11Object and overwrite the values into this object.StringtoString(String indent)
-
-
-
Constructor Detail
-
SALSA20_CHACHA20_POLY1305_PARAMS
public SALSA20_CHACHA20_POLY1305_PARAMS(byte[] nonce, byte[] aad)Create a new CK_SALSA20_CHACHA20_POLY1305_PARAMS object with the given attributes.- Parameters:
nonce- nonce (This should be never re-used with the same key.)
length of nonce in bits (is 64 for original, 96 for IETF (only for chacha20) and 192 for xchacha20/xsalsa20 variant)aad- additional authentication data. This data is authenticated but not encrypted.
-
-
Method Detail
-
getParams
public CK_SALSA20_CHACHA20_POLY1305_PARAMS getParams()
Description copied from class:CkParamsGet this parameters object as an object of the corresponding *_PARAMS class of the iaik.pkcs.pkcs11.wrapper package.
-
setValuesFromPKCS11Object
public void setValuesFromPKCS11Object(Object obj)
Read the parameters from the PKCS11Object and overwrite the values into this object.- Specified by:
setValuesFromPKCS11Objectin interfaceCkMessageParams- Parameters:
obj- Object to read the parameters from
-
getMaxFieldLen
protected int getMaxFieldLen()
- Specified by:
getMaxFieldLenin classCkParams
-
-