mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-03-28 19:21:08 +00:00
misc type fixes in ssl
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
This commit is contained in:
parent
df4d42106a
commit
c37ad4432b
@ -1409,7 +1409,7 @@ int mbedtls_ssl_fetch_input(mbedtls_ssl_context *ssl, size_t nb_want);
|
|||||||
* Write handshake message header
|
* Write handshake message header
|
||||||
*/
|
*/
|
||||||
MBEDTLS_CHECK_RETURN_CRITICAL
|
MBEDTLS_CHECK_RETURN_CRITICAL
|
||||||
int mbedtls_ssl_start_handshake_msg(mbedtls_ssl_context *ssl, unsigned hs_type,
|
int mbedtls_ssl_start_handshake_msg(mbedtls_ssl_context *ssl, unsigned char hs_type,
|
||||||
unsigned char **buf, size_t *buf_len);
|
unsigned char **buf, size_t *buf_len);
|
||||||
|
|
||||||
MBEDTLS_CHECK_RETURN_CRITICAL
|
MBEDTLS_CHECK_RETURN_CRITICAL
|
||||||
|
@ -2731,7 +2731,7 @@ void mbedtls_ssl_send_flight_completed(mbedtls_ssl_context *ssl)
|
|||||||
/*
|
/*
|
||||||
* Handshake layer functions
|
* Handshake layer functions
|
||||||
*/
|
*/
|
||||||
int mbedtls_ssl_start_handshake_msg(mbedtls_ssl_context *ssl, unsigned hs_type,
|
int mbedtls_ssl_start_handshake_msg(mbedtls_ssl_context *ssl, unsigned char hs_type,
|
||||||
unsigned char **buf, size_t *buf_len)
|
unsigned char **buf, size_t *buf_len)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
|
@ -4466,7 +4466,7 @@ int mbedtls_ssl_context_save(mbedtls_ssl_context *ssl,
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if defined(MBEDTLS_SSL_DTLS_CONNECTION_ID)
|
#if defined(MBEDTLS_SSL_DTLS_CONNECTION_ID)
|
||||||
used += 2 + ssl->transform->in_cid_len + ssl->transform->out_cid_len;
|
used += 2U + ssl->transform->in_cid_len + ssl->transform->out_cid_len;
|
||||||
if (used <= buf_len) {
|
if (used <= buf_len) {
|
||||||
*p++ = ssl->transform->in_cid_len;
|
*p++ = ssl->transform->in_cid_len;
|
||||||
memcpy(p, ssl->transform->in_cid, ssl->transform->in_cid_len);
|
memcpy(p, ssl->transform->in_cid, ssl->transform->in_cid_len);
|
||||||
@ -5692,7 +5692,7 @@ int mbedtls_ssl_check_cert_usage(const mbedtls_x509_crt *cert,
|
|||||||
uint32_t *flags)
|
uint32_t *flags)
|
||||||
{
|
{
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
int usage = 0;
|
unsigned int usage = 0;
|
||||||
const char *ext_oid;
|
const char *ext_oid;
|
||||||
size_t ext_len;
|
size_t ext_len;
|
||||||
|
|
||||||
@ -7665,7 +7665,7 @@ static int ssl_calc_finished_tls_generic(mbedtls_ssl_context *ssl, void *ctx,
|
|||||||
unsigned char *padbuf, size_t hlen,
|
unsigned char *padbuf, size_t hlen,
|
||||||
unsigned char *buf, int from)
|
unsigned char *buf, int from)
|
||||||
{
|
{
|
||||||
int len = 12;
|
unsigned int len = 12;
|
||||||
const char *sender;
|
const char *sender;
|
||||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||||
psa_status_t status;
|
psa_status_t status;
|
||||||
@ -7865,7 +7865,8 @@ void mbedtls_ssl_handshake_wrapup(mbedtls_ssl_context *ssl)
|
|||||||
|
|
||||||
int mbedtls_ssl_write_finished(mbedtls_ssl_context *ssl)
|
int mbedtls_ssl_write_finished(mbedtls_ssl_context *ssl)
|
||||||
{
|
{
|
||||||
int ret, hash_len;
|
int ret;
|
||||||
|
unsigned int hash_len;
|
||||||
|
|
||||||
MBEDTLS_SSL_DEBUG_MSG(2, ("=> write finished"));
|
MBEDTLS_SSL_DEBUG_MSG(2, ("=> write finished"));
|
||||||
|
|
||||||
|
@ -3099,8 +3099,8 @@ curve_matching_done:
|
|||||||
mbedtls_pk_type_t sig_alg =
|
mbedtls_pk_type_t sig_alg =
|
||||||
mbedtls_ssl_get_ciphersuite_sig_pk_alg(ciphersuite_info);
|
mbedtls_ssl_get_ciphersuite_sig_pk_alg(ciphersuite_info);
|
||||||
|
|
||||||
unsigned int sig_hash =
|
unsigned char sig_hash =
|
||||||
mbedtls_ssl_tls12_get_preferred_hash_for_sig_alg(
|
(unsigned char) mbedtls_ssl_tls12_get_preferred_hash_for_sig_alg(
|
||||||
ssl, mbedtls_ssl_sig_from_pk_alg(sig_alg));
|
ssl, mbedtls_ssl_sig_from_pk_alg(sig_alg));
|
||||||
|
|
||||||
mbedtls_md_type_t md_alg = mbedtls_ssl_md_alg_from_hash(sig_hash);
|
mbedtls_md_type_t md_alg = mbedtls_ssl_md_alg_from_hash(sig_hash);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user