10. CMOX_GCM

10.1. CMOX GCM PUBLIC CONSTANTS

group CMOX_GCM_PUBLIC_CONSTANTS

10.2. CMOX GCM PUBLIC CONSTANTS:CMOX GCM ALGO

group CMOX_GCM_ALGO

Variables

const cmox_aead_algo_t CMOX_AESSMALL_GCMFAST_ENC_ALGO

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

const cmox_aead_algo_t CMOX_AESSMALL_GCMFAST_DEC_ALGO

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

const cmox_aead_algo_t CMOX_AESFAST_GCMFAST_ENC_ALGO

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

const cmox_aead_algo_t CMOX_AESFAST_GCMFAST_DEC_ALGO

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

const cmox_aead_algo_t CMOX_AESSMALL_GCMSMALL_ENC_ALGO

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

const cmox_aead_algo_t CMOX_AESSMALL_GCMSMALL_DEC_ALGO

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

const cmox_aead_algo_t CMOX_AESFAST_GCMSMALL_ENC_ALGO

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

const cmox_aead_algo_t CMOX_AESFAST_GCMSMALL_DEC_ALGO

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

10.3. CMOX GCM PUBLIC CONSTANTS:CMOX GCM IMPL

group CMOX_GCM_IMPL

Variables

const cmox_gcmSmall_impl_t CMOX_AESFAST_GCMSMALL_ENC

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

const cmox_gcmSmall_impl_t CMOX_AESFAST_GCMSMALL_DEC

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

const cmox_gcmSmall_impl_t CMOX_AESSMALL_GCMSMALL_ENC

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

const cmox_gcmSmall_impl_t CMOX_AESSMALL_GCMSMALL_DEC

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

const cmox_gcmFast_impl_t CMOX_AESFAST_GCMFAST_ENC

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

const cmox_gcmFast_impl_t CMOX_AESFAST_GCMFAST_DEC

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

const cmox_gcmFast_impl_t CMOX_AESSMALL_GCMFAST_ENC

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

const cmox_gcmFast_impl_t CMOX_AESSMALL_GCMFAST_DEC

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

10.4. CMOX GCM PUBLIC METHODS

group CMOX_GCM_PUBLIC_METHODS

Functions

cmox_cipher_handle_t * cmox_gcmSmall_construct ( cmox_gcmSmall_handle_t * P_pThis , cmox_gcmSmall_impl_t P_impl )

GCMSMALL constructor.

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

Note

If CMOX_GCM_IMPLEMENTATION macro has been set to CMOX_GCM_SMALL, this constructor can be called also through the wrapper cmox_gcm_construct

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

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

    • CMOX_AESFAST_GCMSMALL_ENC

    • CMOX_AESFAST_GCMSMALL_DEC

    • CMOX_AESSMALL_GCMSMALL_ENC

    • CMOX_AESSMALL_GCMSMALL_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

cmox_cipher_handle_t * cmox_gcmFast_construct ( cmox_gcmFast_handle_t * P_pThis , cmox_gcmFast_impl_t P_impl )

GCMFAST constructor.

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

Note

If CMOX_GCM_IMPLEMENTATION macro has been set to CMOX_GCM_FAST, this constructor can be called also through the wrapper cmox_gcm_construct

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

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

    • CMOX_AESFAST_GCMFAST_ENC

    • CMOX_AESFAST_GCMFAST_DEC

    • CMOX_AESSMALL_GCMFAST_ENC

    • CMOX_AESSMALL_GCMFAST_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

10.5. CMOX GCM PUBLIC TYPES

group CMOX_GCM_PUBLIC_TYPES

Typedefs

typedef const struct cmox_gcm_gfmulTable_st * cmox_gcm_gfmul_t

Type for specifying the GFMUL operation to use (internally used).

typedef const struct cmox_gcmSmall_implStruct_st * cmox_gcmSmall_impl_t

GCM SMALL mode implementation.

This type specifies the used block cipher for the GCM 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

typedef const struct cmox_gcmFast_implStruct_st * cmox_gcmFast_impl_t

GCM FAST mode implementation.

This type specifies the used block cipher for the GCM 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

typedef uint32_t cmox_gcm_poly_t [ 4 ]

Polynomial type used internally by GCM.

typedef cmox_gcm_poly_t cmox_gcm_table16_t [ 16 ]

Polynomial table type used by GCM SMALL implementation.

typedef cmox_gcm_poly_t cmox_gcm_table8x16_t [ 8 ] [ 16 ]

Polynomial table type used by GCM FAST implementation.

typedef cmox_gcmFast_handle_t cmox_gcm_handle_t

Default GCM handle definition.

typedef cmox_gcmFast_impl_t cmox_gcm_impl_t

Default GCM implementation definition.

struct cmox_gcm_common_t
#include <cmox_gcm.h>

Common fields for both GCM FAST and GCM SMALL handles.

struct cmox_gcmSmall_handle_t
#include <cmox_gcm.h>

GCM SMALL handle structure definition.

struct cmox_gcmFast_handle_t
#include <cmox_gcm.h>

GCM fast context.