Vault 7: Projects

This publication series is about specific projects related to the Vault 7 main publication.

uint8_t * plainText, uint8_t * cipherText, uint32_t numBytes,
void * key, BLOCK_CIPHER_CTR_CONTEXT * context, uint32_t options)
1.7.1.7 GCM
Describes functionality specific to the Galois/Counter Mode (GCM) block cipher mode of operation.
Functions
Name Description
BLOCK_CIPHER_GCM_Initialize Initializes a GCM context for encryption/decryption.
BLOCK_CIPHER_GCM_KeyStreamGenerate Generates a key stream for use with the Galois/counter mode.
BLOCK_CIPHER_GCM_Encrypt Encrypts/authenticates plain text using Galois/counter mode.
BLOCK_CIPHER_GCM_Decrypt Decrypts/authenticates plain text using Galois/counter mode.
Structures
Name Description
BLOCK_CIPHER_GCM_CONTEXT Context structure for the Galois counter operation
Description
Describes functionality specific to the Galois/Counter Mode (GCM) block cipher mode of operation.
1.7.1.7.1 BLOCK_CIPHER_GCM_CONTEXT Structure
File
block_cipher_mode_gcm.h
Syntax
typedef struct {
uint8_t initializationVector[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
uint8_t counter[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
uint8_t hashSubKey[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
uint8_t authTag[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
uint8_t authBuffer[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
BLOCK_CIPHER_FunctionEncrypt encrypt;
BLOCK_CIPHER_FunctionDecrypt decrypt;
void * keyStream;
void * keyStreamCurrentPosition;
uint32_t keyStreamSize;
uint32_t bytesRemainingInKeyStream;
uint32_t blockSize;
uint32_t cipherTextLen;
uint32_t authDataLen;
uint8_t authBufferLen;
struct {
uint8_t authCompleted : 1;
uint8_t filler : 7;
} flags;
} BLOCK_CIPHER_GCM_CONTEXT;
Members
Members Description
uint8_t
initializationVector[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
Buffer containing the initialization vector and initial counter.
uint8_t counter[CRYPTO_CONFIG_BLOCK_MAX_SIZE]; Buffer containing the current counter value.
uint8_t
hashSubKey[CRYPTO_CONFIG_BLOCK_MAX_SIZE];
Buffer containing the calculated hash subkey
uint8_t authTag[CRYPTO_CONFIG_BLOCK_MAX_SIZE]; Buffer containing the current authentication tag
1.7 Library Interface MLA - Crypto Library Help Block Cipher Modes
73

e-Highlighter

Click to send permalink to address bar, or right-click to copy permalink.

Un-highlight all Un-highlight selectionu Highlight selectionh