Skip to content

Commit 740f18c

Browse files
committed
tls: Update export keys callback to use const
Mbed TLS's export keys callback requires the hello.random (for both server and client) to be const. Make the callbacks in Mbed OS that use the key export feature use const to match.
1 parent 1780a08 commit 740f18c

File tree

1 file changed

+2
-2
lines changed
  • features/nanostack/sal-stack-nanostack/source/Security/protocols/tls_sec_prot

1 file changed

+2
-2
lines changed

features/nanostack/sal-stack-nanostack/source/Security/protocols/tls_sec_prot/tls_sec_prot_lib.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,8 @@ static int tls_sec_prot_lib_ssl_send(void *ctx, const unsigned char *buf, size_t
8585
static int tls_sec_prot_lib_ssl_recv(void *ctx, unsigned char *buf, size_t len);
8686
static int tls_sec_prot_lib_ssl_export_keys(void *p_expkey, const unsigned char *ms,
8787
const unsigned char *kb, size_t maclen, size_t keylen,
88-
size_t ivlen, unsigned char client_random[32],
89-
unsigned char server_random[32],
88+
size_t ivlen, const unsigned char client_random[32],
89+
const unsigned char server_random[32],
9090
mbedtls_tls_prf_types tls_prf_type);
9191
#ifdef TLS_SEC_PROT_LIB_TLS_DEBUG
9292
static void tls_sec_prot_lib_debug(void *ctx, int level, const char *file, int line, const char *string);

0 commit comments

Comments
 (0)