24 #ifndef MBEDTLS_ECJPAKE_H 25 #define MBEDTLS_ECJPAKE_H 59 #if !defined(MBEDTLS_ECJPAKE_ALT) 91 #include "ecjpake_alt.h" 127 const unsigned char *secret,
161 unsigned char *buf,
size_t len,
size_t *olen,
162 int (*f_rng)(
void *,
unsigned char *,
size_t),
180 const unsigned char *buf,
202 unsigned char *buf,
size_t len,
size_t *olen,
203 int (*f_rng)(
void *,
unsigned char *,
size_t),
220 const unsigned char *buf,
242 unsigned char *buf,
size_t len,
size_t *olen,
243 int (*f_rng)(
void *,
unsigned char *,
size_t),
256 #if defined(MBEDTLS_SELF_TEST) 263 int mbedtls_ecjpake_self_test(
int verbose );
mbedtls_mpi xm1
Definition: ecjpake.h:84
mbedtls_ecp_point Xp2
Definition: ecjpake.h:81
mbedtls_ecp_point Xp1
Definition: ecjpake.h:80
mbedtls_ecp_point Xm1
Definition: ecjpake.h:78
int mbedtls_ecjpake_check(const mbedtls_ecjpake_context *ctx)
Check if an ECJPAKE context is ready for use.
This file provides an API for Elliptic Curves over GF(P) (ECP).
const mbedtls_md_info_t * md_info
Definition: ecjpake.h:73
int mbedtls_ecjpake_setup(mbedtls_ecjpake_context *ctx, mbedtls_ecjpake_role role, mbedtls_md_type_t hash, mbedtls_ecp_group_id curve, const unsigned char *secret, size_t len)
Set up an ECJPAKE context for use.
int point_format
Definition: ecjpake.h:76
The ECP group structure.
Definition: ecp.h:167
mbedtls_ecp_point Xp
Definition: ecjpake.h:82
mbedtls_ecp_point Xm2
Definition: ecjpake.h:79
mbedtls_ecp_group grp
Definition: ecjpake.h:74
mbedtls_mpi xm2
Definition: ecjpake.h:85
void mbedtls_ecjpake_free(mbedtls_ecjpake_context *ctx)
This clears an ECJPAKE context and frees any embedded data structure.
mbedtls_mpi s
Definition: ecjpake.h:87
int mbedtls_ecjpake_write_round_one(mbedtls_ecjpake_context *ctx, unsigned char *buf, size_t len, size_t *olen, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)
Generate and write the first round message (TLS: contents of the Client/ServerHello extension,...
int mbedtls_ecjpake_write_round_two(mbedtls_ecjpake_context *ctx, unsigned char *buf, size_t len, size_t *olen, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)
Generate and write the second round message (TLS: contents of the Client/ServerKeyExchange).
mbedtls_ecjpake_role role
Definition: ecjpake.h:75
void mbedtls_ecjpake_init(mbedtls_ecjpake_context *ctx)
Initialize an ECJPAKE context.
int mbedtls_ecjpake_derive_secret(mbedtls_ecjpake_context *ctx, unsigned char *buf, size_t len, size_t *olen, int(*f_rng)(void *, unsigned char *, size_t), void *p_rng)
Derive the shared secret (TLS: Pre-Master Secret).
mbedtls_ecp_group_id
Definition: ecp.h:71
mbedtls_ecjpake_role
Definition: ecjpake.h:54
This file contains the generic message-digest wrapper.
struct mbedtls_ecjpake_context mbedtls_ecjpake_context
int mbedtls_ecjpake_read_round_one(mbedtls_ecjpake_context *ctx, const unsigned char *buf, size_t len)
Read and process the first round message (TLS: contents of the Client/ServerHello extension,...
MPI structure.
Definition: bignum.h:180
Definition: md_internal.h:47
The ECP point structure, in Jacobian coordinates.
Definition: ecp.h:118
int mbedtls_ecjpake_read_round_two(mbedtls_ecjpake_context *ctx, const unsigned char *buf, size_t len)
Read and process the second round message (TLS: contents of the Client/ServerKeyExchange).
mbedtls_md_type_t
Supported message digests.
Definition: md.h:58