13. CMOX_XTS

13.1. XTS single-call algorithms

group CMOX_XTS_ALGO

Variables

const cmox_cipher_algo_t CMOX_AESSMALL_XTS_ENC_ALGO

Identifier of the XTS encryption using AES (small implementation) for single-call function (Defined internally).

const cmox_cipher_algo_t CMOX_AESSMALL_XTS_DEC_ALGO

Identifier of the XTS decryption using AES (small implementation) for single-call function (Defined internally).

const cmox_cipher_algo_t CMOX_AESFAST_XTS_ENC_ALGO

Identifier of the XTS encryption using AES (fast implementation) for single-call function (Defined internally).

const cmox_cipher_algo_t CMOX_AESFAST_XTS_DEC_ALGO

Identifier of the XTS decryption using AES (fast implementation) for single-call function (Defined internally).

13.2. XTS implementations

group CMOX_XTS_IMPL

Variables

const cmox_xts_impl_t CMOX_AESFAST_XTS_ENC

Implementation of XTS encryption using AES (fast implementation) (Defined internally).

const cmox_xts_impl_t CMOX_AESFAST_XTS_DEC

Implementation of XTS decryption using AES (fast implementation) (Defined internally).

const cmox_xts_impl_t CMOX_AESSMALL_XTS_ENC

Implementation of XTS encryption using AES (small implementation) (Defined internally).

const cmox_xts_impl_t CMOX_AESSMALL_XTS_DEC

Implementation of XTS decryption using AES (small implementation) (Defined internally).

13.3. XTS public method prototypes

group CMOX_XTS_PUBLIC_METHODS

Functions

cmox_cipher_handle_t * cmox_xts_construct ( cmox_xts_handle_t * P_pThis , cmox_xts_impl_t P_impl )

XTS constructor.

The function is used for specifying which block cipher algorithm to use in order to implement the XTS algorithm and if the algorithm will be used for encryption or decryption.

Parameters :
  • P_pThis – Pointer to the XTS handle to initialize

  • P_impl – Constant that specifies the implementation to use. This parameter can be one of the following values:

    • CMOX_AESFAST_XTS_ENC

    • CMOX_AESFAST_XTS_DEC

    • CMOX_AESSMALL_XTS_ENC

    • CMOX_AESSMALL_XTS_DEC

Returns :

cmox_cipher_handle_t* Pointer to a general cipher handle. This will be used by the general purpose cipher functions in order to perform the algorithm

13.4. XTS public types

group CMOX_XTS_PUBLIC_TYPES

Typedefs

typedef const struct cmox_xts_implStruct_st * cmox_xts_impl_t

XTS mode implementation.

This type specifies the used block cipher for the XTS construct and if the algorithm will be used for encryption or decryption. This type is defined as a pointer to a structure, that contains the functions needed for the specific implementation, defined in the library internally

struct cmox_xts_handle_t
#include <cmox_xts.h>

XTS handle structure definition.

Public Members

cmox_cipher_handle_t super

General cipher handle

cmox_blockcipher_handle_t blockCipher1

Block cipher handle

cmox_blockcipher_handle_t blockCipher2

Block cipher handle

uint32_t tweak [ CMOX_CIPHER_BLOCK_SIZE ]

Temporary result/tweak