Public key information and operations.

Note

  • The library does not support custom pk info structures, only built-in structures returned by mbedtls_cipher_info_from_type().

Public Attributes#

mbedtls_pk_type_t

Public key type.

const char *

Type name.

size_t(*

Get key size in bits.

int(*

Tell if the context implements this type (e.g.

int(*

Verify signature.

int(*

Make signature.

int(*

Decrypt message.

int(*

Encrypt message.

int(*

Check public-private key pair.

void *(*

Allocate a new context.

void(*

Free the given context.

void(*

Interface with the debug module.

Public Attribute Documentation#

type#

mbedtls_pk_type_t mbedtls_pk_info_t::type

Public key type.


Definition at line 36 of file util/third_party/mbedtls/library/pk_wrap.h

name#

const char* mbedtls_pk_info_t::name

Type name.


Definition at line 39 of file util/third_party/mbedtls/library/pk_wrap.h

get_bitlen#

size_t(* mbedtls_pk_info_t::get_bitlen) (mbedtls_pk_context *pk)

Get key size in bits.


Definition at line 42 of file util/third_party/mbedtls/library/pk_wrap.h

can_do#

int(* mbedtls_pk_info_t::can_do) (mbedtls_pk_type_t type)

Tell if the context implements this type (e.g.

ECKEY can do ECDSA)


Definition at line 45 of file util/third_party/mbedtls/library/pk_wrap.h

verify_func#

int(* mbedtls_pk_info_t::verify_func) (mbedtls_pk_context *pk, mbedtls_md_type_t md_alg, const unsigned char *hash, size_t hash_len, const unsigned char *sig, size_t sig_len)

Verify signature.


Definition at line 48 of file util/third_party/mbedtls/library/pk_wrap.h

sign_func#

int(* mbedtls_pk_info_t::sign_func) (mbedtls_pk_context *pk, mbedtls_md_type_t md_alg, const unsigned char *hash, size_t hash_len, unsigned char *sig, size_t sig_size, size_t *sig_len, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)

Make signature.


Definition at line 53 of file util/third_party/mbedtls/library/pk_wrap.h

decrypt_func#

int(* mbedtls_pk_info_t::decrypt_func) (mbedtls_pk_context *pk, const unsigned char *input, size_t ilen, unsigned char *output, size_t *olen, size_t osize, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)

Decrypt message.


Definition at line 75 of file util/third_party/mbedtls/library/pk_wrap.h

encrypt_func#

int(* mbedtls_pk_info_t::encrypt_func) (mbedtls_pk_context *pk, const unsigned char *input, size_t ilen, unsigned char *output, size_t *olen, size_t osize, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)

Encrypt message.


Definition at line 81 of file util/third_party/mbedtls/library/pk_wrap.h

check_pair_func#

int(* mbedtls_pk_info_t::check_pair_func) (mbedtls_pk_context *pub, mbedtls_pk_context *prv, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)

Check public-private key pair.


Definition at line 87 of file util/third_party/mbedtls/library/pk_wrap.h

ctx_alloc_func#

void *(* mbedtls_pk_info_t::ctx_alloc_func) (void)

Allocate a new context.


Definition at line 92 of file util/third_party/mbedtls/library/pk_wrap.h

ctx_free_func#

void(* mbedtls_pk_info_t::ctx_free_func) (void *ctx)

Free the given context.


Definition at line 95 of file util/third_party/mbedtls/library/pk_wrap.h

debug_func#

void(* mbedtls_pk_info_t::debug_func) (mbedtls_pk_context *pk, mbedtls_pk_debug_item *items)

Interface with the debug module.


Definition at line 106 of file util/third_party/mbedtls/library/pk_wrap.h