Vault 7: Projects
This publication series is about specific projects related to the Vault 7 main publication.
options Block cipher encryption options that the user can specify,
or'd together. Valid options for this function are
• BLOCK_CIPHER_OPTION_STREAM_START
• BLOCK_CIPHER_OPTION_STREAM_CONTINUE
• BLOCK_CIPHER_OPTION_STREAM_COMPLETE
•
BLOCK_CIPHER_OPTION_CIPHER_TEXT_POINTER_
ALIGNED
•
BLOCK_CIPHER_OPTION_PLAIN_TEXT_POINTER_A
LIGNED
• BLOCK_CIPHER_OPTION_USE_CFB1
• BLOCK_CIPHER_OPTION_USE_CFB8
• BLOCK_CIPHER_OPTION_USE_CFB_BLOCK_SIZE
Function
void BLOCK_CIPHER_CFB_Encrypt (DRV_HANDLE handle, uint8_t * cipherText,
uint32_t * numCipherBytes, uint8_t * plainText, uint32_t numPlainBytes,
void * key, BLOCK_CIPHER_CFB_CONTEXT * context, uint32_t options);
1.7.1.4.4 BLOCK_CIPHER_CFB_Decrypt Function
Decrypts cipher text using cipher-block chaining mode.
File
block_cipher_mode_cfb.h
Syntax
void BLOCK_CIPHER_CFB_Decrypt(DRV_HANDLE handle, uint8_t * plainText, uint8_t * cipherText,
uint32_t numBytes, void * key, BLOCK_CIPHER_CFB_CONTEXT * context, uint32_t options);
Module
CFB
Returns
None
Description
Decrypts cipher text using cipher-block chaining mode.
Preconditions
The CFB context must be initialized with the block cipher encrypt/decrypt functions and the block cipher algorithm's block
size. The block cipher module must be initialized, if necessary.
Example
// ***************************************************************
// Decrypt data in CFB mode with the AES algorithm.
// ***************************************************************
// System module object variable (for initializing AES)
SYS_MODULE_OBJ sysObject;
// Drive handle variable, to describe which AES module to use
DRV_HANDLE handle;
1.7 Library Interface MLA - Crypto Library Help Block Cipher Modes
53
Protego_Release_01_05-Related-OEM-Documentation-MLA_v2013_12_20-help_mla_crypto.pdf