Lines Matching refs:ext_len
489 size_t ext_len; in ssl_write_cid_ext() local
515 ext_len = (size_t) ssl->own_cid_len + 1; in ssl_write_cid_ext()
516 *p++ = (unsigned char)( ( ext_len >> 8 ) & 0xFF ); in ssl_write_cid_ext()
517 *p++ = (unsigned char)( ( ext_len ) & 0xFF ); in ssl_write_cid_ext()
766 size_t protection_profiles_index = 0, ext_len = 0; in ssl_write_use_srtp_ext() local
795 ext_len = 2 + 2 * ( ssl->conf->dtls_srtp_profile_list_len ) + 1 + mki_len; in ssl_write_use_srtp_ext()
803 MBEDTLS_SSL_CHK_BUF_PTR( p, end, ext_len + 4 ); in ssl_write_use_srtp_ext()
809 *p++ = (unsigned char)( ( ( ext_len & 0xFF00 ) >> 8 ) & 0xFF ); in ssl_write_use_srtp_ext()
810 *p++ = (unsigned char)( ext_len & 0xFF ); in ssl_write_use_srtp_ext()
979 size_t i, n, olen, ext_len = 0; in ssl_write_client_hello() local
1278 if( ( ret = ssl_write_hostname_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1284 ext_len += olen; in ssl_write_client_hello()
1290 if( ( ret = ssl_write_renegotiation_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1296 ext_len += olen; in ssl_write_client_hello()
1301 if( ( ret = ssl_write_signature_algorithms_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1307 ext_len += olen; in ssl_write_client_hello()
1314 if( ( ret = ssl_write_supported_elliptic_curves_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1320 ext_len += olen; in ssl_write_client_hello()
1322 if( ( ret = ssl_write_supported_point_formats_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1328 ext_len += olen; in ssl_write_client_hello()
1333 if( ( ret = ssl_write_ecjpake_kkpp_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1339 ext_len += olen; in ssl_write_client_hello()
1343 if( ( ret = ssl_write_cid_ext( ssl, p + 2 + ext_len, end, &olen ) ) != 0 ) in ssl_write_client_hello()
1348 ext_len += olen; in ssl_write_client_hello()
1352 if( ( ret = ssl_write_max_fragment_length_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1358 ext_len += olen; in ssl_write_client_hello()
1362 if( ( ret = ssl_write_truncated_hmac_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1368 ext_len += olen; in ssl_write_client_hello()
1372 if( ( ret = ssl_write_encrypt_then_mac_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1378 ext_len += olen; in ssl_write_client_hello()
1382 if( ( ret = ssl_write_extended_ms_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1388 ext_len += olen; in ssl_write_client_hello()
1392 if( ( ret = ssl_write_alpn_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1398 ext_len += olen; in ssl_write_client_hello()
1402 if( ( ret = ssl_write_use_srtp_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1408 ext_len += olen; in ssl_write_client_hello()
1412 if( ( ret = ssl_write_session_ticket_ext( ssl, p + 2 + ext_len, in ssl_write_client_hello()
1418 ext_len += olen; in ssl_write_client_hello()
1425 ext_len ) ); in ssl_write_client_hello()
1427 if( ext_len > 0 ) in ssl_write_client_hello()
1431 *p++ = (unsigned char)( ( ext_len >> 8 ) & 0xFF ); in ssl_write_client_hello()
1432 *p++ = (unsigned char)( ( ext_len ) & 0xFF ); in ssl_write_client_hello()
1433 p += ext_len; in ssl_write_client_hello()
2052 size_t ext_len; in ssl_parse_server_hello() local
2192 ext_len = ( ( buf[38 + n] << 8 ) in ssl_parse_server_hello()
2195 if( ( ext_len > 0 && ext_len < 4 ) || in ssl_parse_server_hello()
2196 ssl->in_hslen != mbedtls_ssl_hs_hdr_len( ssl ) + 40 + n + ext_len ) in ssl_parse_server_hello()
2208 ext_len = 0; in ssl_parse_server_hello()
2377 ( "server hello, total extension length: %" MBEDTLS_PRINTF_SIZET, ext_len ) ); in ssl_parse_server_hello()
2379 while( ext_len ) in ssl_parse_server_hello()
2386 if( ext_size + 4 > ext_len ) in ssl_parse_server_hello()
2544 ext_len -= 4 + ext_size; in ssl_parse_server_hello()
2547 if( ext_len > 0 && ext_len < 4 ) in ssl_parse_server_hello()