Lines Matching refs:psk

385         ret = mbedtls_ssl_set_hs_psk(ssl, ssl->conf->psk, ssl->conf->psk_len);  in ssl_tls13_offered_psks_check_identity_match()
414 unsigned char *psk; in ssl_tls13_offered_psks_check_binder_match() local
430 ret = mbedtls_ssl_tls13_export_handshake_psk(ssl, &psk, &psk_len); in ssl_tls13_offered_psks_check_binder_match()
436 psk, psk_len, psk_type, in ssl_tls13_offered_psks_check_binder_match()
440 mbedtls_free((void *) psk); in ssl_tls13_offered_psks_check_binder_match()
524 struct psk_attributes *psk) in ssl_tls13_parse_pre_shared_key_ext() argument
602 &psk->type, &session); in ssl_tls13_parse_pre_shared_key_ext()
609 switch (psk->type) { in ssl_tls13_parse_pre_shared_key_ext()
630 psk->key_exchange_mode = MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_NONE; in ssl_tls13_parse_pre_shared_key_ext()
635 psk->key_exchange_mode = MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL; in ssl_tls13_parse_pre_shared_key_ext()
639 psk->key_exchange_mode = MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK; in ssl_tls13_parse_pre_shared_key_ext()
642 if (psk->key_exchange_mode == MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_NONE) { in ssl_tls13_parse_pre_shared_key_ext()
649 &psk->ciphersuite_info); in ssl_tls13_parse_pre_shared_key_ext()
651 if (psk->ciphersuite_info == NULL) { in ssl_tls13_parse_pre_shared_key_ext()
667 ssl, binder, binder_len, psk->type, in ssl_tls13_parse_pre_shared_key_ext()
668 mbedtls_md_psa_alg_from_type((mbedtls_md_type_t) psk->ciphersuite_info->mac)); in ssl_tls13_parse_pre_shared_key_ext()
688 if (psk->type == MBEDTLS_SSL_TLS1_3_PSK_RESUMPTION) { in ssl_tls13_parse_pre_shared_key_ext()
746 not_using_psk = (ssl->handshake->psk == NULL); in ssl_tls13_write_server_pre_shared_key_ext()
1271 struct psk_attributes psk = PSK_ATTRIBUTES_INIT; in ssl_tls13_parse_client_hello() local
1714 &psk); in ssl_tls13_parse_client_hello()
1747 if (got_psk && (psk.key_exchange_mode == in ssl_tls13_parse_client_hello()
1762 else if (got_psk && (psk.key_exchange_mode == in ssl_tls13_parse_client_hello()
1780 handshake->ciphersuite_info = psk.ciphersuite_info; in ssl_tls13_parse_client_hello()
1781 ssl->session_negotiate->ciphersuite = psk.ciphersuite_info->id; in ssl_tls13_parse_client_hello()
1784 ((unsigned) psk.ciphersuite_info->id), in ssl_tls13_parse_client_hello()
1785 psk.ciphersuite_info->name)); in ssl_tls13_parse_client_hello()
1787 if (psk.type == MBEDTLS_SSL_TLS1_3_PSK_RESUMPTION) { in ssl_tls13_parse_client_hello()