#include <intel-ipsec-mb.h>
Data Fields | ||
const void * | enc_keys | |
const void * | dec_keys | |
uint64_t | key_len_in_bytes | |
union { | ||
const uint8_t * src | ||
const struct IMB_SGL_IOV * sgl_io_segs | ||
}; | ||
union { | ||
uint8_t * dst | ||
uint64_t num_sgl_io_segs | ||
}; | ||
union { | ||
uint64_t cipher_start_src_offset_in_bytes | ||
uint64_t cipher_start_src_offset_in_bits | ||
uint64_t cipher_start_offset_in_bits | ||
}; | ||
union { | ||
uint64_t msg_len_to_cipher_in_bytes | ||
uint64_t msg_len_to_cipher_in_bits | ||
}; | ||
uint64_t | hash_start_src_offset_in_bytes | |
union { | ||
uint64_t msg_len_to_hash_in_bytes | ||
uint64_t msg_len_to_hash_in_bits | ||
}; | ||
const uint8_t * | iv | |
uint64_t | iv_len_in_bytes | |
uint8_t * | auth_tag_output | |
uint64_t | auth_tag_output_len_in_bytes | |
union { | ||
struct _HMAC_specific_fields { | ||
const uint8_t * _hashed_auth_key_xor_ipad | ||
const uint8_t * _hashed_auth_key_xor_opad | ||
} HMAC | ||
struct _AES_XCBC_specific_fields { | ||
const uint32_t * _k1_expanded | ||
const uint8_t * _k2 | ||
const uint8_t * _k3 | ||
} XCBC | ||
struct _AES_CCM_specific_fields { | ||
const void * aad | ||
uint64_t aad_len_in_bytes | ||
} CCM | ||
struct _AES_CMAC_specific_fields { | ||
const void * _key_expanded | ||
const void * _skey1 | ||
const void * _skey2 | ||
} CMAC | ||
struct _AES_GCM_specific_fields { | ||
const void * aad | ||
uint64_t aad_len_in_bytes | ||
struct gcm_context_data * ctx | ||
} GCM | ||
struct _ZUC_EIA3_specific_fields { | ||
const uint8_t * _key | ||
const uint8_t * _iv | ||
const uint8_t * _iv23 | ||
} ZUC_EIA3 | ||
struct _SNOW3G_UIA2_specific_fields { | ||
const void * _key | ||
const void * _iv | ||
} SNOW3G_UIA2 | ||
struct _KASUMI_UIA1_specific_fields { | ||
const void * _key | ||
} KASUMI_UIA1 | ||
struct _AES_GMAC_specific_fields { | ||
const struct gcm_key_data * _key | ||
const void * _iv | ||
uint64_t iv_len_in_bytes | ||
} GMAC | ||
struct _GHASH_specific_fields { | ||
const struct gcm_key_data * _key | ||
const void * _init_tag | ||
} GHASH | ||
struct _POLY1305_specific_fields { | ||
const void * _key | ||
} POLY1305 | ||
struct _CHACHA20_POLY1305_specific_fields { | ||
const void * aad | ||
uint64_t aad_len_in_bytes | ||
struct chacha20_poly1305_context_data * ctx | ||
} CHACHA20_POLY1305 | ||
struct _SNOW_V_AEAD_specific_fields { | ||
const void * aad | ||
uint64_t aad_len_in_bytes | ||
void * reserved | ||
} SNOW_V_AEAD | ||
} | u | |
IMB_STATUS | status | |
IMB_CIPHER_MODE | cipher_mode | |
IMB_CIPHER_DIRECTION | cipher_direction | |
IMB_HASH_ALG | hash_alg | |
IMB_CHAIN_ORDER | chain_order | |
void * | user_data | |
void * | user_data2 | |
int(* | cipher_func )(struct IMB_JOB *) | |
int(* | hash_func )(struct IMB_JOB *) | |
IMB_SGL_STATE | sgl_state | |
union { | ||
struct _CBCS_specific_fields { | ||
void * next_iv | ||
} CBCS | ||
} | cipher_fields | |
uint32_t | suite_id [2] | |
uint32_t | session_id | |
Job structure.
For AES, enc_keys and dec_keys are expected to point to expanded keys structure.
For DES, enc_keys and dec_keys are expected to point to DES key schedule.
For 3DES, enc_keys and dec_keys are expected to point to an array of 3 pointers for the corresponding 3 key schedules.
union { ... } IMB_JOB |
union { ... } IMB_JOB |
union { ... } IMB_JOB |
Offset into input buffer to start ciphering
union { ... } IMB_JOB |
Length of message to cipher
union { ... } IMB_JOB |
Length of message to hash
const uint8_t* IMB_JOB::_hashed_auth_key_xor_ipad |
Hashed result of HMAC key xor'd with ipad (0x36).
const uint8_t* IMB_JOB::_hashed_auth_key_xor_opad |
Hashed result of HMAC key xor'd with opad (0x5c).
const void* IMB_JOB::_init_tag |
initial tag value
const uint8_t* IMB_JOB::_iv |
Authentication 25-byte IV (16-byte aligned)
const void* IMB_JOB::_iv |
Authentication IV (16-byte aligned)
Authentication IV
const uint8_t* IMB_JOB::_iv23 |
Authentication 23-byte IV (16-byte aligned)
const uint32_t* IMB_JOB::_k1_expanded |
k1 expanded key pointer (16-byte aligned)
const uint8_t* IMB_JOB::_k2 |
k2 expanded key pointer (16-byte aligned)
const uint8_t* IMB_JOB::_k3 |
k3 expanded key pointer (16-byte aligned)
const uint8_t* IMB_JOB::_key |
Authentication key (16-byte aligned)
const void* IMB_JOB::_key |
Authentication key (16-byte aligned)
Poly1305 key
const struct gcm_key_data* IMB_JOB::_key |
Authentication key
Expanded GHASH key
const void* IMB_JOB::_key_expanded |
Expanded key (16-byte aligned)
const void* IMB_JOB::_skey1 |
S key 1 (16-byte aligned)
const void* IMB_JOB::_skey2 |
S key 2 (16-byte aligned)
const void* IMB_JOB::aad |
Additional Authentication Data (AAD)
uint64_t IMB_JOB::aad_len_in_bytes |
Length of AAD
uint8_t* IMB_JOB::auth_tag_output |
Authentication tag output
uint64_t IMB_JOB::auth_tag_output_len_in_bytes |
Authentication tag output length in bytes
struct { ... } ::_CBCS_specific_fields IMB_JOB::CBCS |
CBCS specific fields
struct { ... } ::_AES_CCM_specific_fields IMB_JOB::CCM |
AES-CCM specific fields
struct { ... } ::_CHACHA20_POLY1305_specific_fields IMB_JOB::CHACHA20_POLY1305 |
Chacha20-Poly1305 specific fields
IMB_CHAIN_ORDER IMB_JOB::chain_order |
Chain order (IMB_ORDER_CIPHER_HASH / IMB_ORDER_HASH_CIPHER).
IMB_CIPHER_DIRECTION IMB_JOB::cipher_direction |
Cipher direction
union { ... } IMB_JOB::cipher_fields |
Cipher algorithm-specific fields
int(* IMB_JOB::cipher_func) (struct IMB_JOB *) |
Customer cipher function
IMB_CIPHER_MODE IMB_JOB::cipher_mode |
Cipher mode
uint64_t IMB_JOB::cipher_start_offset_in_bits |
Offset into input buffer to start ciphering (in bits)
uint64_t IMB_JOB::cipher_start_src_offset_in_bits |
Offset into input buffer to start ciphering (in bits)
uint64_t IMB_JOB::cipher_start_src_offset_in_bytes |
Offset into input buffer to start ciphering (in bytes)
struct { ... } ::_AES_CMAC_specific_fields IMB_JOB::CMAC |
AES-CMAC specific fields
struct gcm_context_data* IMB_JOB::ctx |
AES-GCM context (for SGL only)
struct chacha20_poly1305_context_data* IMB_JOB::ctx |
Chacha20-Poly1305 context (for SGL only)
const void* IMB_JOB::dec_keys |
Decryption key pointer
uint8_t* IMB_JOB::dst |
Output buffer. May be ciphertext or plaintext. In-place ciphering allowed, i.e. dst = src.
const void* IMB_JOB::enc_keys |
Encryption key pointer
struct { ... } ::_AES_GCM_specific_fields IMB_JOB::GCM |
AES-GCM specific fields
struct { ... } ::_GHASH_specific_fields IMB_JOB::GHASH |
GHASH specific fields
struct { ... } ::_AES_GMAC_specific_fields IMB_JOB::GMAC |
AES-GMAC specific fields
IMB_HASH_ALG IMB_JOB::hash_alg |
Hashing algorithm
int(* IMB_JOB::hash_func) (struct IMB_JOB *) |
Customer hash function
uint64_t IMB_JOB::hash_start_src_offset_in_bytes |
struct { ... } ::_HMAC_specific_fields IMB_JOB::HMAC |
HMAC specific fields
const uint8_t* IMB_JOB::iv |
Initialization Vector (IV)
uint64_t IMB_JOB::iv_len_in_bytes |
IV length in bytes
Authentication IV length in bytes
struct { ... } ::_KASUMI_UIA1_specific_fields IMB_JOB::KASUMI_UIA1 |
KASUMI-UIA2 specific fields
uint64_t IMB_JOB::key_len_in_bytes |
Key length in bytes
uint64_t IMB_JOB::msg_len_to_cipher_in_bits |
Length of message to cipher (in bits)
uint64_t IMB_JOB::msg_len_to_cipher_in_bytes |
Length of message to cipher (in bytes)
uint64_t IMB_JOB::msg_len_to_hash_in_bits |
Length of message to hash (in bits)
uint64_t IMB_JOB::msg_len_to_hash_in_bytes |
Length of message to hash (in bytes)
void* IMB_JOB::next_iv |
Pointer to next IV (last ciphertext block)
uint64_t IMB_JOB::num_sgl_io_segs |
Number of input/output SGL segments
struct { ... } ::_POLY1305_specific_fields IMB_JOB::POLY1305 |
Poly1305 specific fields
void* IMB_JOB::reserved |
Reserved bytes
uint32_t IMB_JOB::session_id |
const struct IMB_SGL_IOV* IMB_JOB::sgl_io_segs |
Pointer to array of input/output SGL segments
IMB_SGL_STATE IMB_JOB::sgl_state |
SGL state (IMB_SGL_INIT/IMB_SGL_UPDATE/IMB_SGL_COMPLETE/ IMB_SGL_ALL)
struct { ... } ::_SNOW3G_UIA2_specific_fields IMB_JOB::SNOW3G_UIA2 |
SNOW3G-UIA2 specific fields
struct { ... } ::_SNOW_V_AEAD_specific_fields IMB_JOB::SNOW_V_AEAD |
SNOW-V AEAD specific fields
const uint8_t* IMB_JOB::src |
Input buffer. May be ciphertext or plaintext. In-place ciphering allowed.
IMB_STATUS IMB_JOB::status |
Job status
uint32_t IMB_JOB::suite_id[2] |
union { ... } IMB_JOB::u |
Hash algorithm-specific fields
void* IMB_JOB::user_data |
Pointer 1 to user data
void* IMB_JOB::user_data2 |
Pointer 2 to user data
struct { ... } ::_AES_XCBC_specific_fields IMB_JOB::XCBC |
AES-XCBC specific fields
struct { ... } ::_ZUC_EIA3_specific_fields IMB_JOB::ZUC_EIA3 |
ZUC-EIA3 specific fields