Class CCM_PARAMS


  • public class CCM_PARAMS
    extends CkParams
    Represents the CK_CCM_PARAMS.
    Author:
    Lijun Liao (xipki)
    • Constructor Detail

      • CCM_PARAMS

        public CCM_PARAMS​(int dataLen,
                          byte[] nonce,
                          byte[] aad,
                          int macLen)
        Create a new CCM_PARAMS object with the given attributes.
        Parameters:
        dataLen - length of the data where 0 ≤ ulDataLen < 2^8L. This length should not include the length of the MAC that is appended to the cipher text. (where L is the size in bytes of the data length's length(2 < L < 8)
        nonce - the nonce
        aad - additional authentication data. This data is authenticated but not encrypted.
        macLen - length of the MAC (output following cipher text) in bytes. Valid values are (4, 6, 8, 10, 12, 14 and 16)
    • Method Detail

      • getParams

        public CK_CCM_PARAMS getParams()
        Description copied from class: CkParams
        Get this parameters object as an object of the corresponding *_PARAMS class of the iaik.pkcs.pkcs11.wrapper package.
        Specified by:
        getParams in class CkParams
        Returns:
        The object of the corresponding *_PARAMS class.
      • setDataLen

        public void setDataLen​(int dataLen)