mbed TLS v1.3.17
Data Fields
cipher_base_t Struct Reference

Base cipher information. More...

#include <cipher.h>

Data Fields

cipher_id_t cipher
 Base Cipher type (e.g. More...
 
int(* ecb_func )(void *ctx, operation_t mode, const unsigned char *input, unsigned char *output)
 Encrypt using ECB. More...
 
int(* cbc_func )(void *ctx, operation_t mode, size_t length, unsigned char *iv, const unsigned char *input, unsigned char *output)
 Encrypt using CBC. More...
 
int(* cfb_func )(void *ctx, operation_t mode, size_t length, size_t *iv_off, unsigned char *iv, const unsigned char *input, unsigned char *output)
 Encrypt using CFB (Full length) More...
 
int(* ctr_func )(void *ctx, size_t length, size_t *nc_off, unsigned char *nonce_counter, unsigned char *stream_block, const unsigned char *input, unsigned char *output)
 Encrypt using CTR. More...
 
int(* stream_func )(void *ctx, size_t length, const unsigned char *input, unsigned char *output)
 Encrypt using STREAM. More...
 
int(* setkey_enc_func )(void *ctx, const unsigned char *key, unsigned int key_length)
 Set key for encryption purposes. More...
 
int(* setkey_dec_func )(void *ctx, const unsigned char *key, unsigned int key_length)
 Set key for decryption purposes. More...
 
void *(* ctx_alloc_func )(void)
 Allocate a new context. More...
 
void(* ctx_free_func )(void *ctx)
 Free the given context. More...
 

Detailed Description

Base cipher information.

The non-mode specific functions and values.

Definition at line 177 of file cipher.h.

Field Documentation

int(* cipher_base_t::cbc_func)(void *ctx, operation_t mode, size_t length, unsigned char *iv, const unsigned char *input, unsigned char *output)

Encrypt using CBC.

Definition at line 188 of file cipher.h.

int(* cipher_base_t::cfb_func)(void *ctx, operation_t mode, size_t length, size_t *iv_off, unsigned char *iv, const unsigned char *input, unsigned char *output)

Encrypt using CFB (Full length)

Definition at line 195 of file cipher.h.

cipher_id_t cipher_base_t::cipher

Base Cipher type (e.g.

POLARSSL_CIPHER_ID_AES)

Definition at line 180 of file cipher.h.

int(* cipher_base_t::ctr_func)(void *ctx, size_t length, size_t *nc_off, unsigned char *nonce_counter, unsigned char *stream_block, const unsigned char *input, unsigned char *output)

Encrypt using CTR.

Definition at line 202 of file cipher.h.

void*(* cipher_base_t::ctx_alloc_func)(void)

Allocate a new context.

Definition at line 222 of file cipher.h.

void(* cipher_base_t::ctx_free_func)(void *ctx)

Free the given context.

Definition at line 225 of file cipher.h.

int(* cipher_base_t::ecb_func)(void *ctx, operation_t mode, const unsigned char *input, unsigned char *output)

Encrypt using ECB.

Definition at line 183 of file cipher.h.

int(* cipher_base_t::setkey_dec_func)(void *ctx, const unsigned char *key, unsigned int key_length)

Set key for decryption purposes.

Definition at line 218 of file cipher.h.

int(* cipher_base_t::setkey_enc_func)(void *ctx, const unsigned char *key, unsigned int key_length)

Set key for encryption purposes.

Definition at line 214 of file cipher.h.

int(* cipher_base_t::stream_func)(void *ctx, size_t length, const unsigned char *input, unsigned char *output)

Encrypt using STREAM.

Definition at line 209 of file cipher.h.


The documentation for this struct was generated from the following file: