Select one of the symbols to view example projects that use it.
 
Outline
#include "stdlib.h"
#include "string.h"
#include "stdio.h"
#include "mbedtls/bignum.h"
#include "mbedtls/entropy.h"
#include "mbedtls/ctr_drbg.h"
#include "esp_random.h"
esp_mpi_t
esp_mpi_ctx_t
esp_mpi_new();
esp_mpi_new_from_hex(const char *);
esp_mpi_new_from_bin(const char *, int);
esp_mpi_free(esp_mpi_t *);
esp_mpi_ctx_new();
esp_mpi_ctx_free(esp_mpi_ctx_t *);
esp_mpi_sizeof(esp_mpi_t *);
esp_mpi_to_bin(esp_mpi_t *, int *);
esp_get_random(void *, unsigned char *, size_t);
esp_mpi_get_rand(esp_mpi_t *, int, int, int);
esp_mpi_a_exp_b_mod_c(esp_mpi_t *, esp_mpi_t *, esp_mpi_t *, esp_mpi_t *, esp_mpi_ctx_t *);
esp_mpi_a_mul_b_mod_c(esp_mpi_t *, esp_mpi_t *, esp_mpi_t *, esp_mpi_t *, esp_mpi_ctx_t *);
esp_mpi_a_add_b_mod_c(esp_mpi_t *, esp_mpi_t *, esp_mpi_t *, esp_mpi_t *, esp_mpi_ctx_t *);
Files
loading (4/5)...
SourceVuESP-IDF Framework and ExamplesESP-IDFcomponents/protocomm/src/crypto/srp6a/esp_srp_mpi.h
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
/* * SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD * * SPDX-License-Identifier: Apache-2.0 *//* ... */ #pragma once #include "stdlib.h" #include "string.h" #include "stdio.h" #include "mbedtls/bignum.h" #include "mbedtls/entropy.h" #include "mbedtls/ctr_drbg.h" #include "esp_random.h"7 includes #ifdef __cplusplus extern "C" { #endif typedef mbedtls_mpi esp_mpi_t; typedef esp_mpi_t esp_mpi_ctx_t; esp_mpi_t *esp_mpi_new(void); esp_mpi_t *esp_mpi_new_from_hex(const char *hex); esp_mpi_t *esp_mpi_new_from_bin(const char *str, int str_len); void esp_mpi_free(esp_mpi_t *bn); esp_mpi_ctx_t *esp_mpi_ctx_new(void); void esp_mpi_ctx_free(esp_mpi_ctx_t *ctx); unsigned int esp_mpi_sizeof(esp_mpi_t *bn); char *esp_mpi_to_bin(esp_mpi_t *bn, int *len); int esp_get_random(void *ctx, unsigned char *data, size_t len); int esp_mpi_get_rand(esp_mpi_t *bn, int bits, int top, int bottom); int esp_mpi_a_exp_b_mod_c(esp_mpi_t *result, esp_mpi_t *a, esp_mpi_t *b, esp_mpi_t *c, esp_mpi_ctx_t *ctx); int esp_mpi_a_mul_b_mod_c(esp_mpi_t *result, esp_mpi_t *a, esp_mpi_t *b, esp_mpi_t *c, esp_mpi_ctx_t *ctx); int esp_mpi_a_add_b_mod_c(esp_mpi_t *result, esp_mpi_t *a, esp_mpi_t *b, esp_mpi_t *c, esp_mpi_ctx_t *ctx); #ifdef __cplusplus }{...} #endif
Details