1a8e1175bSopenharmony_ci#!/bin/sh 2a8e1175bSopenharmony_ci 3a8e1175bSopenharmony_ci# tls13-kex-modes.sh 4a8e1175bSopenharmony_ci# 5a8e1175bSopenharmony_ci# Copyright The Mbed TLS Contributors 6a8e1175bSopenharmony_ci# SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 7a8e1175bSopenharmony_ci# 8a8e1175bSopenharmony_ci 9a8e1175bSopenharmony_ci# DO NOT ADD NEW TEST CASES INTO THIS FILE. The left cases will be generated by 10a8e1175bSopenharmony_ci# scripts in future(#6280) 11a8e1175bSopenharmony_ci 12a8e1175bSopenharmony_cirequires_gnutls_tls1_3 13a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 14a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 15a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk, good" \ 16a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 17a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 18a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 19a8e1175bSopenharmony_ci localhost" \ 20a8e1175bSopenharmony_ci 0 \ 21a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 22a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 23a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 24a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 25a8e1175bSopenharmony_ci -s "Pre shared key found" \ 26a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 27a8e1175bSopenharmony_ci -s "key exchange mode: psk$" \ 28a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 29a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 30a8e1175bSopenharmony_ci 31a8e1175bSopenharmony_cirequires_gnutls_tls1_3 32a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 33a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 34a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk, fail, key id mismatch" \ 35a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 36a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 37a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 38a8e1175bSopenharmony_ci localhost" \ 39a8e1175bSopenharmony_ci 1 \ 40a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 41a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 42a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 43a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 44a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 45a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 46a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 47a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 48a8e1175bSopenharmony_ci 49a8e1175bSopenharmony_cirequires_gnutls_tls1_3 50a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 51a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 52a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk, fail, key material mismatch" \ 53a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 54a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 55a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 56a8e1175bSopenharmony_ci localhost" \ 57a8e1175bSopenharmony_ci 1 \ 58a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 59a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 60a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 61a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 62a8e1175bSopenharmony_ci -s "Invalid binder." \ 63a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 64a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 65a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 66a8e1175bSopenharmony_ci 67a8e1175bSopenharmony_cirequires_gnutls_tls1_3 68a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 69a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 70a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk, good" \ 71a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 72a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 73a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 74a8e1175bSopenharmony_ci localhost" \ 75a8e1175bSopenharmony_ci 0 \ 76a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 77a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 78a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 79a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 80a8e1175bSopenharmony_ci -s "Pre shared key found" \ 81a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 82a8e1175bSopenharmony_ci -s "key exchange mode: psk$" \ 83a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 84a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 85a8e1175bSopenharmony_ci 86a8e1175bSopenharmony_cirequires_gnutls_tls1_3 87a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 88a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 89a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk, fail, key id mismatch" \ 90a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 91a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 92a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 93a8e1175bSopenharmony_ci localhost" \ 94a8e1175bSopenharmony_ci 1 \ 95a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 96a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 97a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 98a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 99a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 100a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 101a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 102a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 103a8e1175bSopenharmony_ci 104a8e1175bSopenharmony_cirequires_gnutls_tls1_3 105a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 106a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 107a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk, fail, key material mismatch" \ 108a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 109a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 110a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 111a8e1175bSopenharmony_ci localhost" \ 112a8e1175bSopenharmony_ci 1 \ 113a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 114a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 115a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 116a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 117a8e1175bSopenharmony_ci -s "Invalid binder." \ 118a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 119a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 120a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 121a8e1175bSopenharmony_ci 122a8e1175bSopenharmony_cirequires_gnutls_tls1_3 123a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 124a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 125a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_ephemeral, good" \ 126a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 127a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 128a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 129a8e1175bSopenharmony_ci localhost" \ 130a8e1175bSopenharmony_ci 0 \ 131a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 132a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 133a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 134a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 135a8e1175bSopenharmony_ci -s "Pre shared key found" \ 136a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 137a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 138a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 139a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 140a8e1175bSopenharmony_ci 141a8e1175bSopenharmony_cirequires_gnutls_tls1_3 142a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 143a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 144a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_ephemeral, fail, key id mismatch" \ 145a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 146a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 147a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 148a8e1175bSopenharmony_ci localhost" \ 149a8e1175bSopenharmony_ci 1 \ 150a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 151a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 152a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 153a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 154a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 155a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 156a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 157a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 158a8e1175bSopenharmony_ci 159a8e1175bSopenharmony_cirequires_gnutls_tls1_3 160a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 161a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 162a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_ephemeral, fail, key material mismatch" \ 163a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 164a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 165a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 166a8e1175bSopenharmony_ci localhost" \ 167a8e1175bSopenharmony_ci 1 \ 168a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 169a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 170a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 171a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 172a8e1175bSopenharmony_ci -s "Invalid binder." \ 173a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 174a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 175a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 176a8e1175bSopenharmony_ci 177a8e1175bSopenharmony_cirequires_gnutls_tls1_3 178a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 179a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 180a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_ephemeral, good" \ 181a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 182a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 183a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 184a8e1175bSopenharmony_ci localhost" \ 185a8e1175bSopenharmony_ci 0 \ 186a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 187a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 188a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 189a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 190a8e1175bSopenharmony_ci -s "Pre shared key found" \ 191a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 192a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 193a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 194a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 195a8e1175bSopenharmony_ci 196a8e1175bSopenharmony_cirequires_gnutls_tls1_3 197a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 198a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 199a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_ephemeral, fail, key id mismatch" \ 200a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 201a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 202a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 203a8e1175bSopenharmony_ci localhost" \ 204a8e1175bSopenharmony_ci 1 \ 205a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 206a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 207a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 208a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 209a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 210a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 211a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 212a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 213a8e1175bSopenharmony_ci 214a8e1175bSopenharmony_cirequires_gnutls_tls1_3 215a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 216a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 217a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_ephemeral, fail, key material mismatch" \ 218a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 219a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 220a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 221a8e1175bSopenharmony_ci localhost" \ 222a8e1175bSopenharmony_ci 1 \ 223a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 224a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 225a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 226a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 227a8e1175bSopenharmony_ci -s "Invalid binder." \ 228a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 229a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 230a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 231a8e1175bSopenharmony_ci 232a8e1175bSopenharmony_cirequires_gnutls_tls1_3 233a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 234a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 235a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk_ephemeral, fail, no common kex mode" \ 236a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 237a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 238a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 239a8e1175bSopenharmony_ci localhost" \ 240a8e1175bSopenharmony_ci 1 \ 241a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 242a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 243a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 244a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 245a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 246a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 247a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 248a8e1175bSopenharmony_ci 249a8e1175bSopenharmony_cirequires_gnutls_tls1_3 250a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 251a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 252a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 253a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_all, good" \ 254a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 255a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 256a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 257a8e1175bSopenharmony_ci localhost" \ 258a8e1175bSopenharmony_ci 0 \ 259a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 260a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 261a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 262a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 263a8e1175bSopenharmony_ci -s "Pre shared key found" \ 264a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 265a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 266a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 267a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 268a8e1175bSopenharmony_ci 269a8e1175bSopenharmony_cirequires_gnutls_tls1_3 270a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 271a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 272a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 273a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_all, fail, key id mismatch" \ 274a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 275a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 276a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 277a8e1175bSopenharmony_ci localhost" \ 278a8e1175bSopenharmony_ci 1 \ 279a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 280a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 281a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 282a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 283a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 284a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 285a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 286a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 287a8e1175bSopenharmony_ci 288a8e1175bSopenharmony_cirequires_gnutls_tls1_3 289a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 290a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 291a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 292a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_all, fail, key material mismatch" \ 293a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 294a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 295a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 296a8e1175bSopenharmony_ci localhost" \ 297a8e1175bSopenharmony_ci 1 \ 298a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 299a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 300a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 301a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 302a8e1175bSopenharmony_ci -s "Invalid binder." \ 303a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 304a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 305a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 306a8e1175bSopenharmony_ci 307a8e1175bSopenharmony_cirequires_gnutls_tls1_3 308a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 309a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 310a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 311a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_all, good" \ 312a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 313a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 314a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 315a8e1175bSopenharmony_ci localhost" \ 316a8e1175bSopenharmony_ci 0 \ 317a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 318a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 319a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 320a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 321a8e1175bSopenharmony_ci -s "Pre shared key found" \ 322a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 323a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 324a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 325a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 326a8e1175bSopenharmony_ci 327a8e1175bSopenharmony_cirequires_gnutls_tls1_3 328a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 329a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 330a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 331a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_all, fail, key id mismatch" \ 332a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 333a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 334a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 335a8e1175bSopenharmony_ci localhost" \ 336a8e1175bSopenharmony_ci 1 \ 337a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 338a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 339a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 340a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 341a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 342a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 343a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 344a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 345a8e1175bSopenharmony_ci 346a8e1175bSopenharmony_cirequires_gnutls_tls1_3 347a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 348a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 349a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 350a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_all, fail, key material mismatch" \ 351a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 352a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 353a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 354a8e1175bSopenharmony_ci localhost" \ 355a8e1175bSopenharmony_ci 1 \ 356a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 357a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 358a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 359a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 360a8e1175bSopenharmony_ci -s "Invalid binder." \ 361a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 362a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 363a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 364a8e1175bSopenharmony_ci 365a8e1175bSopenharmony_cirequires_gnutls_tls1_3 366a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 367a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 368a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 369a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk_all, good" \ 370a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 371a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 372a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 373a8e1175bSopenharmony_ci localhost" \ 374a8e1175bSopenharmony_ci 0 \ 375a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 376a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 377a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 378a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 379a8e1175bSopenharmony_ci -s "Pre shared key found" \ 380a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 381a8e1175bSopenharmony_ci -s "key exchange mode: psk$" \ 382a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 383a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 384a8e1175bSopenharmony_ci 385a8e1175bSopenharmony_cirequires_gnutls_tls1_3 386a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 387a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 388a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 389a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk_all, fail, key id mismatch" \ 390a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 391a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 392a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 393a8e1175bSopenharmony_ci localhost" \ 394a8e1175bSopenharmony_ci 1 \ 395a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 396a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 397a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 398a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 399a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 400a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 401a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 402a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 403a8e1175bSopenharmony_ci 404a8e1175bSopenharmony_cirequires_gnutls_tls1_3 405a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 406a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 407a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 408a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk_all, fail, key material mismatch" \ 409a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 410a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 411a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 412a8e1175bSopenharmony_ci localhost" \ 413a8e1175bSopenharmony_ci 1 \ 414a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 415a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 416a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 417a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 418a8e1175bSopenharmony_ci -s "Invalid binder." \ 419a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 420a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 421a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 422a8e1175bSopenharmony_ci 423a8e1175bSopenharmony_cirequires_gnutls_tls1_3 424a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 425a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 426a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 427a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/ephemeral_all, good" \ 428a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 429a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 430a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 431a8e1175bSopenharmony_ci localhost" \ 432a8e1175bSopenharmony_ci 0 \ 433a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 434a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 435a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 436a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 437a8e1175bSopenharmony_ci -s "Pre shared key found" \ 438a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 439a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 440a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 441a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 442a8e1175bSopenharmony_ci 443a8e1175bSopenharmony_cirequires_gnutls_tls1_3 444a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 445a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 446a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 447a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/ephemeral_all, good, key id mismatch, dhe." \ 448a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 449a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 450a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 451a8e1175bSopenharmony_ci localhost" \ 452a8e1175bSopenharmony_ci 0 \ 453a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 454a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 455a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 456a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 457a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 458a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 459a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 460a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 461a8e1175bSopenharmony_ci 462a8e1175bSopenharmony_cirequires_gnutls_tls1_3 463a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 464a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 465a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 466a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/ephemeral_all, fail, key material mismatch" \ 467a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 468a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 469a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 470a8e1175bSopenharmony_ci localhost" \ 471a8e1175bSopenharmony_ci 1 \ 472a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 473a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 474a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 475a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 476a8e1175bSopenharmony_ci -s "Invalid binder." \ 477a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 478a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 479a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 480a8e1175bSopenharmony_ci 481a8e1175bSopenharmony_cirequires_gnutls_tls1_3 482a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 483a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 484a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 485a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/ephemeral_all, good" \ 486a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 487a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 488a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 489a8e1175bSopenharmony_ci localhost" \ 490a8e1175bSopenharmony_ci 0 \ 491a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 492a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 493a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 494a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 495a8e1175bSopenharmony_ci -s "Pre shared key found" \ 496a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 497a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 498a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 499a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 500a8e1175bSopenharmony_ci 501a8e1175bSopenharmony_cirequires_gnutls_tls1_3 502a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 503a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 504a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 505a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/ephemeral_all, good, key id mismatch, dhe." \ 506a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 507a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 508a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 509a8e1175bSopenharmony_ci localhost" \ 510a8e1175bSopenharmony_ci 0 \ 511a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 512a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 513a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 514a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 515a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 516a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 517a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 518a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 519a8e1175bSopenharmony_ci 520a8e1175bSopenharmony_cirequires_gnutls_tls1_3 521a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 522a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 523a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 524a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/ephemeral_all, fail, key material mismatch" \ 525a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 526a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 527a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 528a8e1175bSopenharmony_ci localhost" \ 529a8e1175bSopenharmony_ci 1 \ 530a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 531a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 532a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 533a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 534a8e1175bSopenharmony_ci -s "Invalid binder." \ 535a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 536a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 537a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 538a8e1175bSopenharmony_ci 539a8e1175bSopenharmony_cirequires_gnutls_tls1_3 540a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 541a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 542a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 543a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/ephemeral_all, good" \ 544a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 545a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 546a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 547a8e1175bSopenharmony_ci localhost" \ 548a8e1175bSopenharmony_ci 0 \ 549a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 550a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 551a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 552a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 553a8e1175bSopenharmony_ci -s "No suitable PSK key exchange mode" \ 554a8e1175bSopenharmony_ci -S "Pre shared key found" \ 555a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 556a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 557a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 558a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 559a8e1175bSopenharmony_ci 560a8e1175bSopenharmony_cirequires_gnutls_tls1_3 561a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 562a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 563a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 564a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 565a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/all, good" \ 566a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 567a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 568a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 569a8e1175bSopenharmony_ci localhost" \ 570a8e1175bSopenharmony_ci 0 \ 571a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 572a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 573a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 574a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 575a8e1175bSopenharmony_ci -s "Pre shared key found" \ 576a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 577a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 578a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 579a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 580a8e1175bSopenharmony_ci 581a8e1175bSopenharmony_cirequires_gnutls_tls1_3 582a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 583a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 584a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 585a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 586a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/all, good, key id mismatch, dhe." \ 587a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 588a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 589a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 590a8e1175bSopenharmony_ci localhost" \ 591a8e1175bSopenharmony_ci 0 \ 592a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 593a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 594a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 595a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 596a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 597a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 598a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 599a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 600a8e1175bSopenharmony_ci 601a8e1175bSopenharmony_cirequires_gnutls_tls1_3 602a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 603a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 604a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 605a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 606a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/all, fail, key material mismatch" \ 607a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 608a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 609a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 610a8e1175bSopenharmony_ci localhost" \ 611a8e1175bSopenharmony_ci 1 \ 612a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 613a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 614a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 615a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 616a8e1175bSopenharmony_ci -s "Invalid binder." \ 617a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 618a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 619a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 620a8e1175bSopenharmony_ci 621a8e1175bSopenharmony_cirequires_gnutls_tls1_3 622a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 623a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 624a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 625a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 626a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/all, good" \ 627a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 628a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 629a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 630a8e1175bSopenharmony_ci localhost" \ 631a8e1175bSopenharmony_ci 0 \ 632a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 633a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 634a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 635a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 636a8e1175bSopenharmony_ci -s "Pre shared key found" \ 637a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 638a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 639a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 640a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 641a8e1175bSopenharmony_ci 642a8e1175bSopenharmony_cirequires_gnutls_tls1_3 643a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 644a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 645a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 646a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 647a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/all, good, key id mismatch, dhe." \ 648a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 649a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 650a8e1175bSopenharmony_ci --pskusername wrong_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 651a8e1175bSopenharmony_ci localhost" \ 652a8e1175bSopenharmony_ci 0 \ 653a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 654a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 655a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 656a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 657a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 658a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 659a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 660a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 661a8e1175bSopenharmony_ci 662a8e1175bSopenharmony_cirequires_gnutls_tls1_3 663a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 664a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 665a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 666a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 667a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/all, fail, key material mismatch" \ 668a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 669a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 670a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 671a8e1175bSopenharmony_ci localhost" \ 672a8e1175bSopenharmony_ci 1 \ 673a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 674a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 675a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 676a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 677a8e1175bSopenharmony_ci -s "Invalid binder." \ 678a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 679a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 680a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 681a8e1175bSopenharmony_ci 682a8e1175bSopenharmony_cirequires_gnutls_tls1_3 683a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 684a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 685a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 686a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 687a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/all, good" \ 688a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 689a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 690a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 691a8e1175bSopenharmony_ci localhost" \ 692a8e1175bSopenharmony_ci 0 \ 693a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 694a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 695a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 696a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 697a8e1175bSopenharmony_ci -s "Pre shared key found" \ 698a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 699a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 700a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 701a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 702a8e1175bSopenharmony_ci 703a8e1175bSopenharmony_cirequires_gnutls_tls1_3 704a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 705a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 706a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 707a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 708a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/all, fail, key material mismatch" \ 709a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 710a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 711a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 712a8e1175bSopenharmony_ci localhost" \ 713a8e1175bSopenharmony_ci 1 \ 714a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 715a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 716a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 717a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 718a8e1175bSopenharmony_ci -s "Invalid binder." \ 719a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 720a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 721a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 722a8e1175bSopenharmony_ci 723a8e1175bSopenharmony_cirequires_gnutls_tls1_3 724a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 725a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 726a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 727a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: ephemeral_all/psk_or_ephemeral, good" \ 728a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 729a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK:+VERS-TLS1.3 \ 730a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 731a8e1175bSopenharmony_ci localhost" \ 732a8e1175bSopenharmony_ci 0 \ 733a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 734a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 735a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 736a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 737a8e1175bSopenharmony_ci -s "No suitable PSK key exchange mode" \ 738a8e1175bSopenharmony_ci -S "Pre shared key found" \ 739a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 740a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 741a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 742a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 743a8e1175bSopenharmony_ci 744a8e1175bSopenharmony_cirequires_gnutls_tls1_3 745a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 746a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 747a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 748a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_or_ephemeral, good" \ 749a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 750a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 751a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 752a8e1175bSopenharmony_ci localhost" \ 753a8e1175bSopenharmony_ci 0 \ 754a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 755a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 756a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 757a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 758a8e1175bSopenharmony_ci -s "Pre shared key found" \ 759a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 760a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 761a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 762a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 763a8e1175bSopenharmony_ci 764a8e1175bSopenharmony_cirequires_gnutls_tls1_3 765a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 766a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 767a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 768a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: all/psk_or_ephemeral, fail, key material mismatch" \ 769a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 770a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3 \ 771a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 772a8e1175bSopenharmony_ci localhost" \ 773a8e1175bSopenharmony_ci 1 \ 774a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 775a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 776a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 777a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 778a8e1175bSopenharmony_ci -s "Invalid binder." \ 779a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 780a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 781a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 782a8e1175bSopenharmony_ci 783a8e1175bSopenharmony_cirequires_gnutls_tls1_3 784a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 785a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 786a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 787a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk_or_ephemeral, good" \ 788a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 789a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 790a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 791a8e1175bSopenharmony_ci localhost" \ 792a8e1175bSopenharmony_ci 0 \ 793a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 794a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 795a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 796a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 797a8e1175bSopenharmony_ci -s "Pre shared key found" \ 798a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 799a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 800a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 801a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 802a8e1175bSopenharmony_ci 803a8e1175bSopenharmony_cirequires_gnutls_tls1_3 804a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 805a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 806a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 807a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_or_ephemeral/psk_or_ephemeral, fail, key material mismatch" \ 808a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 809a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:-ECDHE-PSK:-DHE-PSK:+PSK:+VERS-TLS1.3 \ 810a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f71 \ 811a8e1175bSopenharmony_ci localhost" \ 812a8e1175bSopenharmony_ci 1 \ 813a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 814a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 815a8e1175bSopenharmony_ci -S "Found PSK_EPHEMERAL KEX MODE" \ 816a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 817a8e1175bSopenharmony_ci -s "Invalid binder." \ 818a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 819a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 820a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 821a8e1175bSopenharmony_ci 822a8e1175bSopenharmony_cirequires_gnutls_tls1_3 823a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 824a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 825a8e1175bSopenharmony_cirequires_config_enabled PSA_WANT_ALG_ECDH 826a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_ephemeral group(secp256r1) check, good" \ 827a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 828a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3:-GROUP-ALL:+GROUP-SECP256R1 \ 829a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 830a8e1175bSopenharmony_ci localhost" \ 831a8e1175bSopenharmony_ci 0 \ 832a8e1175bSopenharmony_ci -s "write selected_group: secp256r1" \ 833a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 834a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 835a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 836a8e1175bSopenharmony_ci 837a8e1175bSopenharmony_cirequires_gnutls_tls1_3 838a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 839a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 840a8e1175bSopenharmony_cirequires_config_enabled PSA_WANT_ALG_ECDH 841a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_ephemeral group(secp384r1) check, good" \ 842a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 843a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3:-GROUP-ALL:+GROUP-SECP384R1 \ 844a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 845a8e1175bSopenharmony_ci localhost" \ 846a8e1175bSopenharmony_ci 0 \ 847a8e1175bSopenharmony_ci -s "write selected_group: secp384r1" \ 848a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 849a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 850a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 851a8e1175bSopenharmony_ci 852a8e1175bSopenharmony_cirequires_gnutls_tls1_3 853a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 854a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 855a8e1175bSopenharmony_cirequires_config_enabled PSA_WANT_ALG_ECDH 856a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_ephemeral group(secp521r1) check, good" \ 857a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 858a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3:-GROUP-ALL:+GROUP-SECP521R1 \ 859a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 860a8e1175bSopenharmony_ci localhost" \ 861a8e1175bSopenharmony_ci 0 \ 862a8e1175bSopenharmony_ci -s "write selected_group: secp521r1" \ 863a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 864a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 865a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 866a8e1175bSopenharmony_ci 867a8e1175bSopenharmony_cirequires_gnutls_tls1_3 868a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 869a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 870a8e1175bSopenharmony_cirequires_config_enabled PSA_WANT_ALG_ECDH 871a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_ephemeral group(x25519) check, good" \ 872a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 873a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3:-GROUP-ALL:+GROUP-X25519 \ 874a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 875a8e1175bSopenharmony_ci localhost" \ 876a8e1175bSopenharmony_ci 0 \ 877a8e1175bSopenharmony_ci -s "write selected_group: x25519" \ 878a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 879a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 880a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 881a8e1175bSopenharmony_ci 882a8e1175bSopenharmony_cirequires_gnutls_tls1_3 883a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 884a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 885a8e1175bSopenharmony_cirequires_config_enabled PSA_WANT_ALG_ECDH 886a8e1175bSopenharmony_cirun_test "TLS 1.3: G->m: psk_ephemeral group(x448) check, good" \ 887a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 888a8e1175bSopenharmony_ci "$G_NEXT_CLI -d 10 --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3:-GROUP-ALL:+GROUP-X448 \ 889a8e1175bSopenharmony_ci --pskusername Client_identity --pskkey=6162636465666768696a6b6c6d6e6f70 \ 890a8e1175bSopenharmony_ci localhost" \ 891a8e1175bSopenharmony_ci 0 \ 892a8e1175bSopenharmony_ci -s "write selected_group: x448" \ 893a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 894a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 895a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 896a8e1175bSopenharmony_ci 897a8e1175bSopenharmony_cirequires_openssl_tls1_3 898a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 899a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 900a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk, fail, no common kex mode" \ 901a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 902a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 903a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 904a8e1175bSopenharmony_ci 1 \ 905a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 906a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 907a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 908a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 909a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 910a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 911a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 912a8e1175bSopenharmony_ci 913a8e1175bSopenharmony_cirequires_openssl_tls1_3 914a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 915a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 916a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk, good" \ 917a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 918a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 919a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 920a8e1175bSopenharmony_ci 0 \ 921a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 922a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 923a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 924a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 925a8e1175bSopenharmony_ci -s "Pre shared key found" \ 926a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 927a8e1175bSopenharmony_ci -s "key exchange mode: psk$" \ 928a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 929a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 930a8e1175bSopenharmony_ci 931a8e1175bSopenharmony_cirequires_openssl_tls1_3 932a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 933a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 934a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk, fail, key id mismatch" \ 935a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 936a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 937a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 938a8e1175bSopenharmony_ci 1 \ 939a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 940a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 941a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 942a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 943a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 944a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 945a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 946a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 947a8e1175bSopenharmony_ci 948a8e1175bSopenharmony_cirequires_openssl_tls1_3 949a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 950a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 951a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk, fail, key material mismatch" \ 952a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk debug_level=5 $(get_srv_psk_list)" \ 953a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 954a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 955a8e1175bSopenharmony_ci 1 \ 956a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 957a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 958a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 959a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 960a8e1175bSopenharmony_ci -s "Invalid binder." \ 961a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 962a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 963a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 964a8e1175bSopenharmony_ci 965a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 966a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 967a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 968a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_ephemeral, good" \ 969a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 970a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 971a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 972a8e1175bSopenharmony_ci 0 \ 973a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 974a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 975a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 976a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 977a8e1175bSopenharmony_ci -s "Pre shared key found" \ 978a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 979a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 980a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 981a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 982a8e1175bSopenharmony_ci 983a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 984a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 985a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 986a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_ephemeral, fail, key id mismatch" \ 987a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 988a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 989a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 990a8e1175bSopenharmony_ci 1 \ 991a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 992a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 993a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 994a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 995a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 996a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 997a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 998a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 999a8e1175bSopenharmony_ci 1000a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1001a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1002a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1003a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_ephemeral, fail, key material mismatch" \ 1004a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1005a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1006a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1007a8e1175bSopenharmony_ci 1 \ 1008a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1009a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1010a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1011a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1012a8e1175bSopenharmony_ci -s "Invalid binder." \ 1013a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1014a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1015a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1016a8e1175bSopenharmony_ci 1017a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1018a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1019a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1020a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_ephemeral, good" \ 1021a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1022a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1023a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1024a8e1175bSopenharmony_ci 0 \ 1025a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1026a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1027a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1028a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1029a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1030a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1031a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1032a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1033a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1034a8e1175bSopenharmony_ci 1035a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1036a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1037a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1038a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_ephemeral, fail, key id mismatch" \ 1039a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1040a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1041a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1042a8e1175bSopenharmony_ci 1 \ 1043a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1044a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1045a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1046a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1047a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1048a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1049a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1050a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1051a8e1175bSopenharmony_ci 1052a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1053a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1054a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1055a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_ephemeral, fail, key material mismatch" \ 1056a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1057a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1058a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1059a8e1175bSopenharmony_ci 1 \ 1060a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1061a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1062a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1063a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1064a8e1175bSopenharmony_ci -s "Invalid binder." \ 1065a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1066a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1067a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1068a8e1175bSopenharmony_ci 1069a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1070a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1071a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1072a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1073a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_all, good" \ 1074a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 1075a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1076a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1077a8e1175bSopenharmony_ci 0 \ 1078a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1079a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1080a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1081a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1082a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1083a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1084a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1085a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1086a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1087a8e1175bSopenharmony_ci 1088a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1089a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1090a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1091a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1092a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_all, fail, key id mismatch" \ 1093a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 1094a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1095a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1096a8e1175bSopenharmony_ci 1 \ 1097a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1098a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1099a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1100a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1101a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1102a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1103a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1104a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1105a8e1175bSopenharmony_ci 1106a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1107a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1108a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1109a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1110a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_all, fail, key material mismatch" \ 1111a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 1112a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1113a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1114a8e1175bSopenharmony_ci 1 \ 1115a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1116a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1117a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1118a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1119a8e1175bSopenharmony_ci -s "Invalid binder." \ 1120a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1121a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1122a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1123a8e1175bSopenharmony_ci 1124a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1125a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1126a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1127a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1128a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_all, good" \ 1129a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 1130a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1131a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1132a8e1175bSopenharmony_ci 0 \ 1133a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1134a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1135a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1136a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1137a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1138a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1139a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1140a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1141a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1142a8e1175bSopenharmony_ci 1143a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1144a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1145a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1146a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1147a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_all, fail, key id mismatch" \ 1148a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 1149a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1150a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1151a8e1175bSopenharmony_ci 1 \ 1152a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1153a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1154a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1155a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1156a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1157a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1158a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1159a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1160a8e1175bSopenharmony_ci 1161a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1162a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1163a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1164a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1165a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_all, fail, key material mismatch" \ 1166a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_all debug_level=5 $(get_srv_psk_list)" \ 1167a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1168a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1169a8e1175bSopenharmony_ci 1 \ 1170a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1171a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1172a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1173a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1174a8e1175bSopenharmony_ci -s "Invalid binder." \ 1175a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1176a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1177a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1178a8e1175bSopenharmony_ci 1179a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1180a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1181a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1182a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1183a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/ephemeral_all, good" \ 1184a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 1185a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1186a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1187a8e1175bSopenharmony_ci 0 \ 1188a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1189a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1190a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1191a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1192a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1193a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1194a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1195a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1196a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1197a8e1175bSopenharmony_ci 1198a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1199a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1200a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1201a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1202a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/ephemeral_all, good, key id mismatch, dhe." \ 1203a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 1204a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1205a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1206a8e1175bSopenharmony_ci 0 \ 1207a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1208a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1209a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1210a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1211a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1212a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1213a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1214a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 1215a8e1175bSopenharmony_ci 1216a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1217a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1218a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1219a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1220a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/ephemeral_all, fail, key material mismatch" \ 1221a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 1222a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1223a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1224a8e1175bSopenharmony_ci 1 \ 1225a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1226a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1227a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1228a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1229a8e1175bSopenharmony_ci -s "Invalid binder." \ 1230a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1231a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1232a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1233a8e1175bSopenharmony_ci 1234a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1235a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1236a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1237a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1238a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/ephemeral_all, good" \ 1239a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 1240a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1241a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1242a8e1175bSopenharmony_ci 0 \ 1243a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1244a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1245a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1246a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1247a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1248a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1249a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1250a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1251a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1252a8e1175bSopenharmony_ci 1253a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1254a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1255a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1256a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1257a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/ephemeral_all, good, key id mismatch, dhe." \ 1258a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 1259a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1260a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1261a8e1175bSopenharmony_ci 0 \ 1262a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1263a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1264a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1265a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1266a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1267a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1268a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1269a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 1270a8e1175bSopenharmony_ci 1271a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1272a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1273a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1274a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1275a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/ephemeral_all, fail, key material mismatch" \ 1276a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=ephemeral_all debug_level=5 $(get_srv_psk_list)" \ 1277a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1278a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1279a8e1175bSopenharmony_ci 1 \ 1280a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1281a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1282a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1283a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1284a8e1175bSopenharmony_ci -s "Invalid binder." \ 1285a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1286a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1287a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1288a8e1175bSopenharmony_ci 1289a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1290a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1291a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1292a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1293a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1294a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/all, good" \ 1295a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 1296a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1297a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1298a8e1175bSopenharmony_ci 0 \ 1299a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1300a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1301a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1302a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1303a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1304a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1305a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1306a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1307a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1308a8e1175bSopenharmony_ci 1309a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1310a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1311a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1312a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1313a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1314a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/all, good, key id mismatch, dhe." \ 1315a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 1316a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1317a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1318a8e1175bSopenharmony_ci 0 \ 1319a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1320a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1321a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1322a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1323a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1324a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1325a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1326a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 1327a8e1175bSopenharmony_ci 1328a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1329a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1330a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1331a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1332a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1333a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/all, fail, key material mismatch" \ 1334a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 1335a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1336a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1337a8e1175bSopenharmony_ci 1 \ 1338a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1339a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1340a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1341a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1342a8e1175bSopenharmony_ci -s "Invalid binder." \ 1343a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1344a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1345a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1346a8e1175bSopenharmony_ci 1347a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1348a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1349a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1350a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1351a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1352a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/all, good" \ 1353a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 1354a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1355a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1356a8e1175bSopenharmony_ci 0 \ 1357a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1358a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1359a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1360a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1361a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1362a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1363a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1364a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1365a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1366a8e1175bSopenharmony_ci 1367a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1368a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1369a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1370a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1371a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1372a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/all, good, key id mismatch, dhe." \ 1373a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 1374a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1375a8e1175bSopenharmony_ci -psk_identity wrong_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1376a8e1175bSopenharmony_ci 0 \ 1377a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1378a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1379a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1380a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1381a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1382a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1383a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1384a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 1385a8e1175bSopenharmony_ci 1386a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1387a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1388a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1389a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1390a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1391a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/all, fail, key material mismatch" \ 1392a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=all debug_level=5 $(get_srv_psk_list)" \ 1393a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1394a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1395a8e1175bSopenharmony_ci 1 \ 1396a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1397a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1398a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1399a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1400a8e1175bSopenharmony_ci -s "Invalid binder." \ 1401a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1402a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1403a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1404a8e1175bSopenharmony_ci 1405a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1406a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1407a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1408a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1409a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: ephemeral_all/psk_or_ephemeral, good" \ 1410a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1411a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg \ 1412a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1413a8e1175bSopenharmony_ci 0 \ 1414a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1415a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1416a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1417a8e1175bSopenharmony_ci -S "Found PSK KEX MODE" \ 1418a8e1175bSopenharmony_ci -s "No suitable PSK key exchange mode" \ 1419a8e1175bSopenharmony_ci -S "Pre shared key found" \ 1420a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1421a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1422a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1423a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 1424a8e1175bSopenharmony_ci 1425a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1426a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1427a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1428a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1429a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_or_ephemeral, good" \ 1430a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1431a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1432a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1433a8e1175bSopenharmony_ci 0 \ 1434a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1435a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1436a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1437a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1438a8e1175bSopenharmony_ci -s "Pre shared key found" \ 1439a8e1175bSopenharmony_ci -S "No usable PSK or ticket" \ 1440a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1441a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1442a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 1443a8e1175bSopenharmony_ci 1444a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1445a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1446a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1447a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1448a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: all/psk_or_ephemeral, fail, key material mismatch" \ 1449a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_or_ephemeral debug_level=5 $(get_srv_psk_list)" \ 1450a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex \ 1451a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f71" \ 1452a8e1175bSopenharmony_ci 1 \ 1453a8e1175bSopenharmony_ci -s "found psk key exchange modes extension" \ 1454a8e1175bSopenharmony_ci -s "found pre_shared_key extension" \ 1455a8e1175bSopenharmony_ci -s "Found PSK_EPHEMERAL KEX MODE" \ 1456a8e1175bSopenharmony_ci -s "Found PSK KEX MODE" \ 1457a8e1175bSopenharmony_ci -s "Invalid binder." \ 1458a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1459a8e1175bSopenharmony_ci -S "key exchange mode: psk_ephemeral" \ 1460a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1461a8e1175bSopenharmony_ci 1462a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1463a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1464a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1465a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: psk_ephemeral group(secp256r1) check, good" \ 1466a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 1467a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex -groups P-256 \ 1468a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1469a8e1175bSopenharmony_ci 0 \ 1470a8e1175bSopenharmony_ci -s "write selected_group: secp256r1" \ 1471a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1472a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1473a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1474a8e1175bSopenharmony_ci 1475a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1476a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1477a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1478a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: psk_ephemeral group(secp384r1) check, good" \ 1479a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 1480a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex -groups secp384r1 \ 1481a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1482a8e1175bSopenharmony_ci 0 \ 1483a8e1175bSopenharmony_ci -s "write selected_group: secp384r1" \ 1484a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1485a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1486a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1487a8e1175bSopenharmony_ci 1488a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1489a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1490a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1491a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: psk_ephemeral group(secp521r1) check, good" \ 1492a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 1493a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex -groups secp521r1 \ 1494a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1495a8e1175bSopenharmony_ci 0 \ 1496a8e1175bSopenharmony_ci -s "write selected_group: secp521r1" \ 1497a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1498a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1499a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1500a8e1175bSopenharmony_ci 1501a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1502a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1503a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1504a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: psk_ephemeral group(x25519) check, good" \ 1505a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 1506a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex -groups X25519 \ 1507a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1508a8e1175bSopenharmony_ci 0 \ 1509a8e1175bSopenharmony_ci -s "write selected_group: x25519" \ 1510a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1511a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1512a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1513a8e1175bSopenharmony_ci 1514a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1515a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1516a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1517a8e1175bSopenharmony_cirun_test "TLS 1.3: O->m: psk_ephemeral group(x448) check, good" \ 1518a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_identity=Client_identity psk=6162636465666768696a6b6c6d6e6f70" \ 1519a8e1175bSopenharmony_ci "$O_NEXT_CLI -tls1_3 -msg -allow_no_dhe_kex -groups X448 \ 1520a8e1175bSopenharmony_ci -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70" \ 1521a8e1175bSopenharmony_ci 0 \ 1522a8e1175bSopenharmony_ci -s "write selected_group: x448" \ 1523a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1524a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1525a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1526a8e1175bSopenharmony_ci 1527a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1528a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 1529a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1530a8e1175bSopenharmony_cirun_test "TLS 1.3 O->m: psk_ephemeral group(secp256r1->secp384r1) check, good" \ 1531a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_list=Client_identity,6162636465666768696a6b6c6d6e6f70,abc,dead,def,beef groups=secp384r1" \ 1532a8e1175bSopenharmony_ci "$O_NEXT_CLI_NO_CERT -tls1_3 -msg -allow_no_dhe_kex -psk_identity Client_identity -psk 6162636465666768696a6b6c6d6e6f70 -groups P-256:P-384" \ 1533a8e1175bSopenharmony_ci 0 \ 1534a8e1175bSopenharmony_ci -s "write selected_group: secp384r1" \ 1535a8e1175bSopenharmony_ci -s "HRR selected_group: secp384r1" \ 1536a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1537a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1538a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1539a8e1175bSopenharmony_ci 1540a8e1175bSopenharmony_cirequires_all_configs_enabled MBEDTLS_SSL_PROTO_TLS1_3 MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE MBEDTLS_SSL_SRV_C MBEDTLS_DEBUG_C 1541a8e1175bSopenharmony_cirequires_gnutls_tls1_3 1542a8e1175bSopenharmony_cirequires_gnutls_next_no_ticket 1543a8e1175bSopenharmony_cirequires_gnutls_next_disable_tls13_compat 1544a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1545a8e1175bSopenharmony_cirequires_config_enabled PSA_WANT_ALG_ECDH 1546a8e1175bSopenharmony_cirun_test "TLS 1.3 G->m: psk_ephemeral group(secp256r1->secp384r1) check, good" \ 1547a8e1175bSopenharmony_ci "$P_SRV tls13_kex_modes=psk_ephemeral debug_level=5 psk_list=Client_identity,6162636465666768696a6b6c6d6e6f70,abc,dead,def,beef groups=secp384r1" \ 1548a8e1175bSopenharmony_ci "$G_NEXT_CLI_NO_CERT --debug=4 --single-key-share --priority NORMAL:-VERS-ALL:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK:+VERS-TLS1.3:-GROUP-ALL:+GROUP-SECP256R1:+GROUP-SECP384R1 --pskusername Client_identity --pskkey 6162636465666768696a6b6c6d6e6f70 localhost" \ 1549a8e1175bSopenharmony_ci 0 \ 1550a8e1175bSopenharmony_ci -s "write selected_group: secp384r1" \ 1551a8e1175bSopenharmony_ci -s "HRR selected_group: secp384r1" \ 1552a8e1175bSopenharmony_ci -S "key exchange mode: psk$" \ 1553a8e1175bSopenharmony_ci -s "key exchange mode: psk_ephemeral" \ 1554a8e1175bSopenharmony_ci -S "key exchange mode: ephemeral" 1555a8e1175bSopenharmony_ci 1556a8e1175bSopenharmony_ci 1557a8e1175bSopenharmony_ci# Add psk test cases for mbedtls client code 1558a8e1175bSopenharmony_ci 1559a8e1175bSopenharmony_ci# MbedTls->MbedTLS kinds of tls13_kex_modes 1560a8e1175bSopenharmony_ci# PSK mode in client 1561a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1562a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1563a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1564a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1565a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk, good" \ 1566a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1567a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1568a8e1175bSopenharmony_ci 0 \ 1569a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1570a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1571a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1572a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 1573a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1574a8e1175bSopenharmony_ci 1575a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1576a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1577a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1578a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1579a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk, fail, key id mismatch" \ 1580a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1581a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk" \ 1582a8e1175bSopenharmony_ci 1 \ 1583a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1584a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1585a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1586a8e1175bSopenharmony_ci -s "No usable PSK or ticket" 1587a8e1175bSopenharmony_ci 1588a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1589a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1590a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1591a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1592a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk, fail, key material mismatch" \ 1593a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1594a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk_identity=0a0b0c psk=040506 tls13_kex_modes=psk" \ 1595a8e1175bSopenharmony_ci 1 \ 1596a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1597a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1598a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1599a8e1175bSopenharmony_ci -s "Invalid binder." 1600a8e1175bSopenharmony_ci 1601a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1602a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1603a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1604a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1605a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1606a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk_ephemeral, fail - no common kex mode" \ 1607a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1608a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1609a8e1175bSopenharmony_ci 1 \ 1610a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1611a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1612a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1613a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1614a8e1175bSopenharmony_ci 1615a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1616a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1617a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1618a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1619a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1620a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/ephemeral, fail - no common kex mode" \ 1621a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1622a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1623a8e1175bSopenharmony_ci 1 \ 1624a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1625a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1626a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1627a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1628a8e1175bSopenharmony_ci 1629a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1630a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1631a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1632a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1633a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1634a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1635a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/ephemeral_all, fail - no common kex mode" \ 1636a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 1637a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1638a8e1175bSopenharmony_ci 1 \ 1639a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1640a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1641a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1642a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1643a8e1175bSopenharmony_ci 1644a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1645a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1646a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1647a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1648a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1649a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk_all, good" \ 1650a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1651a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1652a8e1175bSopenharmony_ci 0 \ 1653a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1654a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1655a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1656a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 1657a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1658a8e1175bSopenharmony_ci 1659a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1660a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1661a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1662a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1663a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1664a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk_all, fail, key id mismatch" \ 1665a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1666a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk" \ 1667a8e1175bSopenharmony_ci 1 \ 1668a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1669a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1670a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1671a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1672a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1673a8e1175bSopenharmony_ci 1674a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1675a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1676a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1677a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1678a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1679a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/psk_all, fail, key material mismatch" \ 1680a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1681a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk_identity=0a0b0c psk=040506 tls13_kex_modes=psk" \ 1682a8e1175bSopenharmony_ci 1 \ 1683a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1684a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1685a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1686a8e1175bSopenharmony_ci -s "Invalid binder." 1687a8e1175bSopenharmony_ci 1688a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1689a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1690a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1691a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1692a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1693a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1694a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/all, good" \ 1695a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 1696a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1697a8e1175bSopenharmony_ci 0 \ 1698a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1699a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1700a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1701a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 1702a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1703a8e1175bSopenharmony_ci 1704a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1705a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1706a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1707a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1708a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1709a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1710a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/all, fail, key id mismatch" \ 1711a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 1712a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk" \ 1713a8e1175bSopenharmony_ci 1 \ 1714a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1715a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1716a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1717a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1718a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1719a8e1175bSopenharmony_ci 1720a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1721a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1722a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1723a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1724a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1725a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1726a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk/all, fail, key material mismatch" \ 1727a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 1728a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c psk=040506 tls13_kex_modes=psk" \ 1729a8e1175bSopenharmony_ci 1 \ 1730a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1731a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1732a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1733a8e1175bSopenharmony_ci -s "Invalid binder." 1734a8e1175bSopenharmony_ci 1735a8e1175bSopenharmony_ci# psk_ephemeral mode in client 1736a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1737a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1738a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1739a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1740a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1741a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk, fail - no common kex mode" \ 1742a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1743a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1744a8e1175bSopenharmony_ci 1 \ 1745a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1746a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1747a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1748a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1749a8e1175bSopenharmony_ci 1750a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1751a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1752a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1753a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1754a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk_ephemeral, good" \ 1755a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1756a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1757a8e1175bSopenharmony_ci 0 \ 1758a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1759a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1760a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1761a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 1762a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1763a8e1175bSopenharmony_ci 1764a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1765a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1766a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1767a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1768a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk_ephemeral, fail, key id mismatch" \ 1769a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1770a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_ephemeral" \ 1771a8e1175bSopenharmony_ci 1 \ 1772a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1773a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1774a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1775a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1776a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1777a8e1175bSopenharmony_ci 1778a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1779a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1780a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1781a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1782a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk_ephemeral, fail, key material mismatch" \ 1783a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1784a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c psk=040506 tls13_kex_modes=psk_ephemeral" \ 1785a8e1175bSopenharmony_ci 1 \ 1786a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1787a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1788a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1789a8e1175bSopenharmony_ci -s "Invalid binder." 1790a8e1175bSopenharmony_ci 1791a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1792a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1793a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1794a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 1795a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1796a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1797a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/ephemeral, fail - no common kex mode" \ 1798a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1799a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1800a8e1175bSopenharmony_ci 1 \ 1801a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1802a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1803a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" 1804a8e1175bSopenharmony_ci 1805a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1806a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1807a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1808a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1809a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1810a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/ephemeral_all, good" \ 1811a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 1812a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1813a8e1175bSopenharmony_ci 0 \ 1814a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1815a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1816a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1817a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 1818a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1819a8e1175bSopenharmony_ci 1820a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1821a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 1822a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1823a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1824a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1825a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1826a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/ephemeral_all, fail, key id mismatch" \ 1827a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 1828a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_ephemeral" \ 1829a8e1175bSopenharmony_ci 1 \ 1830a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1831a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1832a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1833a8e1175bSopenharmony_ci -s "No usable PSK or ticket" 1834a8e1175bSopenharmony_ci 1835a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1836a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1837a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1838a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1839a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1840a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/ephemeral_all, fail, key material mismatch" \ 1841a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 1842a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c psk=040506 tls13_kex_modes=psk_ephemeral" \ 1843a8e1175bSopenharmony_ci 1 \ 1844a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1845a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1846a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1847a8e1175bSopenharmony_ci -s "Invalid binder." 1848a8e1175bSopenharmony_ci 1849a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1850a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1851a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1852a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1853a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1854a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk_all, good" \ 1855a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1856a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1857a8e1175bSopenharmony_ci 0 \ 1858a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1859a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1860a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1861a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 1862a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1863a8e1175bSopenharmony_ci 1864a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1865a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1866a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1867a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1868a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1869a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk_all, fail, key id mismatch" \ 1870a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1871a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_ephemeral" \ 1872a8e1175bSopenharmony_ci 1 \ 1873a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1874a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1875a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1876a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1877a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1878a8e1175bSopenharmony_ci 1879a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1880a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1881a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1882a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1883a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1884a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/psk_all, fail, key material mismatch" \ 1885a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1886a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1887a8e1175bSopenharmony_ci 1 \ 1888a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1889a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1890a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1891a8e1175bSopenharmony_ci -s "Invalid binder." 1892a8e1175bSopenharmony_ci 1893a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1894a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1895a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1896a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1897a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1898a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1899a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/all, good" \ 1900a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 1901a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1902a8e1175bSopenharmony_ci 0 \ 1903a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1904a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1905a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1906a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 1907a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1908a8e1175bSopenharmony_ci 1909a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1910a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1911a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1912a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1913a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1914a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1915a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/all, fail, key id mismatch" \ 1916a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 1917a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_ephemeral" \ 1918a8e1175bSopenharmony_ci 1 \ 1919a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1920a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1921a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1922a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 1923a8e1175bSopenharmony_ci 1924a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1925a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1926a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1927a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1928a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1929a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1930a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_ephemeral/all, fail, key material mismatch" \ 1931a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 1932a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1933a8e1175bSopenharmony_ci 1 \ 1934a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 1935a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 1936a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 1937a8e1175bSopenharmony_ci -s "Invalid binder." 1938a8e1175bSopenharmony_ci 1939a8e1175bSopenharmony_ci# ephemeral mode in client 1940a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1941a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1942a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1943a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1944a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1945a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral/psk, fail - no common kex mode" \ 1946a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 1947a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1948a8e1175bSopenharmony_ci 1 \ 1949a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1950a8e1175bSopenharmony_ci 1951a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1952a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1953a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1954a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1955a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1956a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral/psk_ephemeral, fail - no common kex mode" \ 1957a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 1958a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1959a8e1175bSopenharmony_ci 1 \ 1960a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1961a8e1175bSopenharmony_ci 1962a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1963a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1964a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1965a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1966a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral/ephemeral, good" \ 1967a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1968a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1969a8e1175bSopenharmony_ci 0 \ 1970a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 1971a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1972a8e1175bSopenharmony_ci 1973a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1974a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1975a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1976a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1977a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1978a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral/ephemeral_all, good" \ 1979a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 1980a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1981a8e1175bSopenharmony_ci 0 \ 1982a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 1983a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 1984a8e1175bSopenharmony_ci 1985a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1986a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1987a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 1988a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 1989a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 1990a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 1991a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral/psk_all, fail - no common kex mode" \ 1992a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 1993a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 1994a8e1175bSopenharmony_ci 1 \ 1995a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 1996a8e1175bSopenharmony_ci 1997a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 1998a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 1999a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2000a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2001a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2002a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2003a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral/all, good" \ 2004a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2005a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 2006a8e1175bSopenharmony_ci 0 \ 2007a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 2008a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2009a8e1175bSopenharmony_ci 2010a8e1175bSopenharmony_ci# ephemeral_all mode in client 2011a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2012a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2013a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2014a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2015a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2016a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2017a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk, fail - no common kex mode" \ 2018a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2019a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2020a8e1175bSopenharmony_ci 1 \ 2021a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2022a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2023a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2024a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2025a8e1175bSopenharmony_ci 2026a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2027a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2028a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2029a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2030a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2031a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk_ephemeral, good" \ 2032a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2033a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2034a8e1175bSopenharmony_ci 0 \ 2035a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2036a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2037a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2038a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2039a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2040a8e1175bSopenharmony_ci 2041a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2042a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2043a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2044a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2045a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2046a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk_ephemeral, fail, key id mismatch" \ 2047a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2048a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=ephemeral_all" \ 2049a8e1175bSopenharmony_ci 1 \ 2050a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2051a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2052a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2053a8e1175bSopenharmony_ci -s "No usable PSK or ticket" 2054a8e1175bSopenharmony_ci 2055a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2056a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2057a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2058a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2059a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2060a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk_ephemeral, fail, key material mismatch" \ 2061a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2062a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2063a8e1175bSopenharmony_ci 1 \ 2064a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2065a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2066a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2067a8e1175bSopenharmony_ci -s "Invalid binder." 2068a8e1175bSopenharmony_ci 2069a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2070a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2071a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2072a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2073a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2074a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/ephemeral, good" \ 2075a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 2076a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2077a8e1175bSopenharmony_ci 0 \ 2078a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2079a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2080a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2081a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" \ 2082a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 2083a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2084a8e1175bSopenharmony_ci 2085a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2086a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2087a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2088a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2089a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2090a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/ephemeral_all, good" \ 2091a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2092a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2093a8e1175bSopenharmony_ci 0 \ 2094a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2095a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2096a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2097a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2098a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2099a8e1175bSopenharmony_ci 2100a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2101a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2102a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2103a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2104a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2105a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/ephemeral_all,good,key id mismatch,fallback" \ 2106a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2107a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=ephemeral_all" \ 2108a8e1175bSopenharmony_ci 0 \ 2109a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2110a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2111a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2112a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2113a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 2114a8e1175bSopenharmony_ci 2115a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2116a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2117a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2118a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2119a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2120a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/ephemeral_all, fail, key material mismatch" \ 2121a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2122a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2123a8e1175bSopenharmony_ci 1 \ 2124a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2125a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2126a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2127a8e1175bSopenharmony_ci -s "Invalid binder." 2128a8e1175bSopenharmony_ci 2129a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2130a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2131a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2132a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2133a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2134a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2135a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk_all, good" \ 2136a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2137a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2138a8e1175bSopenharmony_ci 0 \ 2139a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2140a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2141a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2142a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2143a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2144a8e1175bSopenharmony_ci 2145a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2146a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2147a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2148a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2149a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2150a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2151a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk_all, fail, key id mismatch" \ 2152a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2153a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=ephemeral_all" \ 2154a8e1175bSopenharmony_ci 1 \ 2155a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2156a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2157a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2158a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2159a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2160a8e1175bSopenharmony_ci 2161a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2162a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2163a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2164a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2165a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2166a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2167a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/psk_all, fail, key material mismatch" \ 2168a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2169a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2170a8e1175bSopenharmony_ci 1 \ 2171a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2172a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2173a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2174a8e1175bSopenharmony_ci -s "Invalid binder." 2175a8e1175bSopenharmony_ci 2176a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2177a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2178a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2179a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2180a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2181a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2182a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/all, good" \ 2183a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2184a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2185a8e1175bSopenharmony_ci 0 \ 2186a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2187a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2188a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2189a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2190a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2191a8e1175bSopenharmony_ci 2192a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2193a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2194a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2195a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2196a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2197a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2198a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/all, good, key id mismatch, fallback" \ 2199a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2200a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=ephemeral_all" \ 2201a8e1175bSopenharmony_ci 0 \ 2202a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2203a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2204a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2205a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2206a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 2207a8e1175bSopenharmony_ci 2208a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2209a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2210a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2211a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2212a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2213a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2214a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: ephemeral_all/all, fail, key material mismatch" \ 2215a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2216a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2217a8e1175bSopenharmony_ci 1 \ 2218a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2219a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2220a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2221a8e1175bSopenharmony_ci -s "Invalid binder." 2222a8e1175bSopenharmony_ci 2223a8e1175bSopenharmony_ci# psk_all mode in client 2224a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2225a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2226a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2227a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2228a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2229a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk, good" \ 2230a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2231a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2232a8e1175bSopenharmony_ci 0 \ 2233a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2234a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2235a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2236a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 2237a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2238a8e1175bSopenharmony_ci 2239a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2240a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2241a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2242a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2243a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2244a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk, fail, key id mismatch" \ 2245a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2246a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_all" \ 2247a8e1175bSopenharmony_ci 1 \ 2248a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2249a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2250a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2251a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2252a8e1175bSopenharmony_ci 2253a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2254a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2255a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2256a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2257a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2258a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk, fail, key material mismatch" \ 2259a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2260a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2261a8e1175bSopenharmony_ci 1 \ 2262a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2263a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2264a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2265a8e1175bSopenharmony_ci -s "Invalid binder." 2266a8e1175bSopenharmony_ci 2267a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2268a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2269a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2270a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2271a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2272a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk_ephemeral, good" \ 2273a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2274a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2275a8e1175bSopenharmony_ci 0 \ 2276a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2277a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2278a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2279a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2280a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2281a8e1175bSopenharmony_ci 2282a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2283a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2284a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2285a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2286a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2287a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk_ephemeral, fail, key id mismatch" \ 2288a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2289a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_all" \ 2290a8e1175bSopenharmony_ci 1 \ 2291a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2292a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2293a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2294a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2295a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2296a8e1175bSopenharmony_ci 2297a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2298a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2299a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2300a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2301a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2302a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk_ephemeral, fail, key material mismatch" \ 2303a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2304a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2305a8e1175bSopenharmony_ci 1 \ 2306a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2307a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2308a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2309a8e1175bSopenharmony_ci -s "Invalid binder." 2310a8e1175bSopenharmony_ci 2311a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2312a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2313a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2314a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2315a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2316a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2317a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/ephemeral, fail - no common kex mode" \ 2318a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 2319a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2320a8e1175bSopenharmony_ci 1 \ 2321a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2322a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2323a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" 2324a8e1175bSopenharmony_ci 2325a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2326a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2327a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2328a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2329a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2330a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2331a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/ephemeral_all, good" \ 2332a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2333a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2334a8e1175bSopenharmony_ci 0 \ 2335a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2336a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2337a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2338a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2339a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2340a8e1175bSopenharmony_ci 2341a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2342a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2343a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2344a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2345a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2346a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2347a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/ephemeral_all, fail, key id mismatch" \ 2348a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2349a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_all" \ 2350a8e1175bSopenharmony_ci 1 \ 2351a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2352a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2353a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2354a8e1175bSopenharmony_ci -s "No usable PSK or ticket" 2355a8e1175bSopenharmony_ci 2356a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2357a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2358a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2359a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2360a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2361a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2362a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/ephemeral_all, fail, key material mismatch" \ 2363a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2364a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2365a8e1175bSopenharmony_ci 1 \ 2366a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2367a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2368a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2369a8e1175bSopenharmony_ci -s "Invalid binder." 2370a8e1175bSopenharmony_ci 2371a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2372a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2373a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2374a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2375a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2376a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk_all, good" \ 2377a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2378a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2379a8e1175bSopenharmony_ci 0 \ 2380a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2381a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2382a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2383a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2384a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2385a8e1175bSopenharmony_ci 2386a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2387a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2388a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2389a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2390a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2391a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk_all, fail, key id mismatch" \ 2392a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2393a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_all" \ 2394a8e1175bSopenharmony_ci 1 \ 2395a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2396a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2397a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2398a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2399a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2400a8e1175bSopenharmony_ci 2401a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2402a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2403a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2404a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2405a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2406a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/psk_all, fail, key material mismatch" \ 2407a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2408a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2409a8e1175bSopenharmony_ci 1 \ 2410a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2411a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2412a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2413a8e1175bSopenharmony_ci -s "Invalid binder." 2414a8e1175bSopenharmony_ci 2415a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2416a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2417a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2418a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2419a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2420a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2421a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/all, good" \ 2422a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2423a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2424a8e1175bSopenharmony_ci 0 \ 2425a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2426a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2427a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2428a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2429a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2430a8e1175bSopenharmony_ci 2431a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2432a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2433a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2434a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2435a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2436a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2437a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/all, fail, key id mismatch" \ 2438a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2439a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=psk_all" \ 2440a8e1175bSopenharmony_ci 1 \ 2441a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2442a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2443a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2444a8e1175bSopenharmony_ci -s "No usable PSK or ticket" 2445a8e1175bSopenharmony_ci 2446a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2447a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2448a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2449a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2450a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2451a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2452a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: psk_all/all, fail, key material mismatch" \ 2453a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2454a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2455a8e1175bSopenharmony_ci 1 \ 2456a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2457a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2458a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2459a8e1175bSopenharmony_ci -s "Invalid binder." 2460a8e1175bSopenharmony_ci 2461a8e1175bSopenharmony_ci# all mode in client 2462a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2463a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2464a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2465a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2466a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2467a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2468a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk, good" \ 2469a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2470a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2471a8e1175bSopenharmony_ci 0 \ 2472a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2473a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2474a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2475a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 2476a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2477a8e1175bSopenharmony_ci 2478a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2479a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2480a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2481a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2482a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2483a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2484a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk, fail, key id mismatch" \ 2485a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2486a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=all" \ 2487a8e1175bSopenharmony_ci 1 \ 2488a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2489a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2490a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2491a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2492a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2493a8e1175bSopenharmony_ci 2494a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2495a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2496a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2497a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2498a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2499a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2500a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk, fail, key material mismatch" \ 2501a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2502a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=all" \ 2503a8e1175bSopenharmony_ci 1 \ 2504a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2505a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2506a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2507a8e1175bSopenharmony_ci -s "Invalid binder." 2508a8e1175bSopenharmony_ci 2509a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2510a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2511a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2512a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2513a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2514a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2515a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk_ephemeral, good" \ 2516a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2517a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2518a8e1175bSopenharmony_ci 0 \ 2519a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2520a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2521a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2522a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2523a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2524a8e1175bSopenharmony_ci 2525a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2526a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2527a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2528a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2529a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2530a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2531a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk_ephemeral, fail, key id mismatch" \ 2532a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2533a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=all" \ 2534a8e1175bSopenharmony_ci 1 \ 2535a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2536a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2537a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2538a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2539a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2540a8e1175bSopenharmony_ci 2541a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2542a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2543a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2544a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2545a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2546a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2547a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk_ephemeral, fail, key material mismatch" \ 2548a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2549a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=all" \ 2550a8e1175bSopenharmony_ci 1 \ 2551a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2552a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2553a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2554a8e1175bSopenharmony_ci -s "Invalid binder." 2555a8e1175bSopenharmony_ci 2556a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2557a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2558a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2559a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2560a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2561a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2562a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/ephemeral, good" \ 2563a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 2564a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2565a8e1175bSopenharmony_ci 0 \ 2566a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2567a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2568a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2569a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 2570a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2571a8e1175bSopenharmony_ci 2572a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2573a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2574a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2575a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2576a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2577a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2578a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/ephemeral_all, good" \ 2579a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2580a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2581a8e1175bSopenharmony_ci 0 \ 2582a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2583a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2584a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2585a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2586a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2587a8e1175bSopenharmony_ci 2588a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2589a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2590a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2591a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2592a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2593a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2594a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/ephemeral_all, good, key id mismatch, fallback" \ 2595a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2596a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=all" \ 2597a8e1175bSopenharmony_ci 0 \ 2598a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2599a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2600a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2601a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2602a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 2603a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2604a8e1175bSopenharmony_ci 2605a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2606a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2607a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2608a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2609a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2610a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2611a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/ephemeral_all, fail, key material mismatch" \ 2612a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2613a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=all" \ 2614a8e1175bSopenharmony_ci 1 \ 2615a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2616a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2617a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2618a8e1175bSopenharmony_ci -s "Invalid binder." 2619a8e1175bSopenharmony_ci 2620a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2621a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2622a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2623a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2624a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2625a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2626a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk_all, good" \ 2627a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2628a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2629a8e1175bSopenharmony_ci 0 \ 2630a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2631a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2632a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2633a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2634a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2635a8e1175bSopenharmony_ci 2636a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2637a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2638a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2639a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2640a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2641a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2642a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk_all, fail, key id mismatch" \ 2643a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2644a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=all" \ 2645a8e1175bSopenharmony_ci 1 \ 2646a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2647a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2648a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2649a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2650a8e1175bSopenharmony_ci -s "ClientHello message misses mandatory extensions." 2651a8e1175bSopenharmony_ci 2652a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2653a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2654a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2655a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2656a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2657a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2658a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/psk_all, fail, key material mismatch" \ 2659a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2660a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=all" \ 2661a8e1175bSopenharmony_ci 1 \ 2662a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2663a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2664a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2665a8e1175bSopenharmony_ci -s "Invalid binder." 2666a8e1175bSopenharmony_ci 2667a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2668a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2669a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2670a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2671a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2672a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2673a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/all, good" \ 2674a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2675a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2676a8e1175bSopenharmony_ci 0 \ 2677a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2678a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2679a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2680a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2681a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2682a8e1175bSopenharmony_ci 2683a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2684a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2685a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2686a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2687a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2688a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2689a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/all, good, key id mismatch, fallback" \ 2690a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2691a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=010203 psk_identity=0d0e0f tls13_kex_modes=all" \ 2692a8e1175bSopenharmony_ci 0 \ 2693a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2694a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2695a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2696a8e1175bSopenharmony_ci -s "No usable PSK or ticket" \ 2697a8e1175bSopenharmony_ci -s "key exchange mode: ephemeral" 2698a8e1175bSopenharmony_ci 2699a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2700a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_SRV_C 2701a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2702a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2703a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2704a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2705a8e1175bSopenharmony_cirun_test "TLS 1.3: m->m: all/all, fail, key material mismatch" \ 2706a8e1175bSopenharmony_ci "$P_SRV nbio=2 debug_level=5 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2707a8e1175bSopenharmony_ci "$P_CLI nbio=2 debug_level=5 psk=040506 psk_identity=0a0b0c tls13_kex_modes=all" \ 2708a8e1175bSopenharmony_ci 1 \ 2709a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2710a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2711a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2712a8e1175bSopenharmony_ci -s "Invalid binder." 2713a8e1175bSopenharmony_ci 2714a8e1175bSopenharmony_ci#OPENSSL-SERVER psk mode 2715a8e1175bSopenharmony_cirequires_openssl_tls1_3 2716a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2717a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2718a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2719a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2720a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2721a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: psk/all, good" \ 2722a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203 -allow_no_dhe_kex -nocert" \ 2723a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2724a8e1175bSopenharmony_ci 0 \ 2725a8e1175bSopenharmony_ci -c "=> write client hello" \ 2726a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2727a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2728a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2729a8e1175bSopenharmony_ci -c "<= write client hello" \ 2730a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 2731a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2732a8e1175bSopenharmony_ci 2733a8e1175bSopenharmony_cirequires_openssl_tls1_3 2734a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2735a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2736a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2737a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2738a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2739a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: psk/ephemeral_all, fail - no common kex mode" \ 2740a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203" \ 2741a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2742a8e1175bSopenharmony_ci 1 \ 2743a8e1175bSopenharmony_ci -c "=> write client hello" \ 2744a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2745a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2746a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2747a8e1175bSopenharmony_ci -c "<= write client hello" \ 2748a8e1175bSopenharmony_ci -c "Last error was: -0x7780 - SSL - A fatal alert message was received from our peer" 2749a8e1175bSopenharmony_ci 2750a8e1175bSopenharmony_ci#OPENSSL-SERVER psk_all mode 2751a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2752a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2753a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2754a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2755a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2756a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2757a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2758a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: psk_all/all, good" \ 2759a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203 -allow_no_dhe_kex -nocert" \ 2760a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2761a8e1175bSopenharmony_ci 0 \ 2762a8e1175bSopenharmony_ci -c "=> write client hello" \ 2763a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2764a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2765a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2766a8e1175bSopenharmony_ci -c "<= write client hello" \ 2767a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2768a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2769a8e1175bSopenharmony_ci 2770a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2771a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2772a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2773a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2774a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2775a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2776a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2777a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: psk_all/ephemeral_all, good" \ 2778a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203" \ 2779a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2780a8e1175bSopenharmony_ci 0 \ 2781a8e1175bSopenharmony_ci -c "=> write client hello" \ 2782a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2783a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2784a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2785a8e1175bSopenharmony_ci -c "<= write client hello" \ 2786a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2787a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2788a8e1175bSopenharmony_ci 2789a8e1175bSopenharmony_ci#OPENSSL-SERVER psk_ephemeral mode 2790a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2791a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2792a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2793a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2794a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2795a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2796a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: psk_ephemeral/all, good" \ 2797a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203 -allow_no_dhe_kex -nocert" \ 2798a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2799a8e1175bSopenharmony_ci 0 \ 2800a8e1175bSopenharmony_ci -c "=> write client hello" \ 2801a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2802a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2803a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2804a8e1175bSopenharmony_ci -c "<= write client hello" \ 2805a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2806a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2807a8e1175bSopenharmony_ci 2808a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2809a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2810a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2811a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2812a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2813a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2814a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: psk_ephemeral/ephemeral_all, good" \ 2815a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203" \ 2816a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 2817a8e1175bSopenharmony_ci 0 \ 2818a8e1175bSopenharmony_ci -c "=> write client hello" \ 2819a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2820a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2821a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2822a8e1175bSopenharmony_ci -c "<= write client hello" \ 2823a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2824a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2825a8e1175bSopenharmony_ci 2826a8e1175bSopenharmony_ci#OPENSSL-SERVER ephemeral mode 2827a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2828a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2829a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2830a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2831a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2832a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2833a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: ephemeral/all, good" \ 2834a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203 -allow_no_dhe_kex" \ 2835a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 2836a8e1175bSopenharmony_ci 0 \ 2837a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 2838a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2839a8e1175bSopenharmony_ci 2840a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2841a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2842a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2843a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2844a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2845a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2846a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: ephemeral/ephemeral_all, good" \ 2847a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203" \ 2848a8e1175bSopenharmony_ci "$P_CLI debug_level=4 sig_algs=ecdsa_secp256r1_sha256 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 2849a8e1175bSopenharmony_ci 0 \ 2850a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 2851a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2852a8e1175bSopenharmony_ci 2853a8e1175bSopenharmony_ci#OPENSSL-SERVER ephemeral_all mode 2854a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2855a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2856a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2857a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2858a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2859a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2860a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2861a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: ephemeral_all/all, good" \ 2862a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203 -allow_no_dhe_kex -nocert" \ 2863a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2864a8e1175bSopenharmony_ci 0 \ 2865a8e1175bSopenharmony_ci -c "=> write client hello" \ 2866a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2867a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2868a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2869a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2870a8e1175bSopenharmony_ci -c "<= write client hello" \ 2871a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2872a8e1175bSopenharmony_ci 2873a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2874a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2875a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2876a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2877a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2878a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2879a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2880a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: ephemeral_all/ephemeral_all, good" \ 2881a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203" \ 2882a8e1175bSopenharmony_ci "$P_CLI debug_level=4 sig_algs=ecdsa_secp256r1_sha256 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 2883a8e1175bSopenharmony_ci 0 \ 2884a8e1175bSopenharmony_ci -c "=> write client hello" \ 2885a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2886a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2887a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2888a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2889a8e1175bSopenharmony_ci -c "<= write client hello" \ 2890a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2891a8e1175bSopenharmony_ci 2892a8e1175bSopenharmony_ci#OPENSSL-SERVER all mode 2893a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2894a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2895a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2896a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2897a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2898a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2899a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2900a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2901a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: all/all, good" \ 2902a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203 -allow_no_dhe_kex -nocert" \ 2903a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2904a8e1175bSopenharmony_ci 0 \ 2905a8e1175bSopenharmony_ci -c "=> write client hello" \ 2906a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2907a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2908a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2909a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2910a8e1175bSopenharmony_ci -c "<= write client hello" \ 2911a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2912a8e1175bSopenharmony_ci 2913a8e1175bSopenharmony_cirequires_openssl_tls1_3_with_compatible_ephemeral 2914a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2915a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2916a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2917a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2918a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2919a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 2920a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2921a8e1175bSopenharmony_cirun_test "TLS 1.3: m->O: all/ephemeral_all, good" \ 2922a8e1175bSopenharmony_ci "$O_NEXT_SRV -msg -debug -tls1_3 -psk_identity 0a0b0c -psk 010203" \ 2923a8e1175bSopenharmony_ci "$P_CLI debug_level=4 sig_algs=ecdsa_secp256r1_sha256 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 2924a8e1175bSopenharmony_ci 0 \ 2925a8e1175bSopenharmony_ci -c "=> write client hello" \ 2926a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2927a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2928a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2929a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2930a8e1175bSopenharmony_ci -c "<= write client hello" \ 2931a8e1175bSopenharmony_ci -c "HTTP/1.0 200 ok" 2932a8e1175bSopenharmony_ci 2933a8e1175bSopenharmony_ci#GNUTLS-SERVER psk mode 2934a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2935a8e1175bSopenharmony_cirequires_gnutls_tls1_3 2936a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2937a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2938a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2939a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2940a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: psk/all, good" \ 2941a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK --pskpasswd=data_files/simplepass.psk" \ 2942a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2943a8e1175bSopenharmony_ci 0 \ 2944a8e1175bSopenharmony_ci -c "=> write client hello" \ 2945a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2946a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2947a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2948a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 2949a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 2950a8e1175bSopenharmony_ci -c "<= write client hello" \ 2951a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk$" \ 2952a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2953a8e1175bSopenharmony_ci 2954a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2955a8e1175bSopenharmony_cirequires_gnutls_tls1_3 2956a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2957a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2958a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2959a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2960a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: psk/ephemeral_all, fail - no common kex mode" \ 2961a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK --pskpasswd=data_files/simplepass.psk" \ 2962a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk" \ 2963a8e1175bSopenharmony_ci 1 \ 2964a8e1175bSopenharmony_ci -c "=> write client hello" \ 2965a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2966a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2967a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2968a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 2969a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 2970a8e1175bSopenharmony_ci -c "<= write client hello" \ 2971a8e1175bSopenharmony_ci -c "Last error was: -0x7780 - SSL - A fatal alert message was received from our peer" 2972a8e1175bSopenharmony_ci 2973a8e1175bSopenharmony_ci#GNUTLS-SERVER psk_all mode 2974a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2975a8e1175bSopenharmony_cirequires_gnutls_tls1_3 2976a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2977a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2978a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 2979a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 2980a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 2981a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: psk_all/all, good" \ 2982a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK --pskpasswd=data_files/simplepass.psk" \ 2983a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 2984a8e1175bSopenharmony_ci 0 \ 2985a8e1175bSopenharmony_ci -c "=> write client hello" \ 2986a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 2987a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 2988a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 2989a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 2990a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 2991a8e1175bSopenharmony_ci -c "<= write client hello" \ 2992a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 2993a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 2994a8e1175bSopenharmony_ci 2995a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 2996a8e1175bSopenharmony_cirequires_gnutls_tls1_3 2997a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 2998a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 2999a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3000a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 3001a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3002a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: psk_all/ephemeral_all, good" \ 3003a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK --pskpasswd=data_files/simplepass.psk" \ 3004a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_all" \ 3005a8e1175bSopenharmony_ci 0 \ 3006a8e1175bSopenharmony_ci -c "=> write client hello" \ 3007a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3008a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3009a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3010a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3011a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3012a8e1175bSopenharmony_ci -c "<= write client hello" \ 3013a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3014a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3015a8e1175bSopenharmony_ci 3016a8e1175bSopenharmony_ci#GNUTLS-SERVER psk_ephemeral mode 3017a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3018a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3019a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3020a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3021a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3022a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3023a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: psk_ephemeral/all, good" \ 3024a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK --pskpasswd=data_files/simplepass.psk" \ 3025a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 3026a8e1175bSopenharmony_ci 0 \ 3027a8e1175bSopenharmony_ci -c "=> write client hello" \ 3028a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3029a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3030a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3031a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3032a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3033a8e1175bSopenharmony_ci -c "<= write client hello" \ 3034a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3035a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3036a8e1175bSopenharmony_ci 3037a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3038a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3039a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3040a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3041a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3042a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3043a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: psk_ephemeral/ephemeral_all, good" \ 3044a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK --pskpasswd=data_files/simplepass.psk" \ 3045a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=psk_ephemeral" \ 3046a8e1175bSopenharmony_ci 0 \ 3047a8e1175bSopenharmony_ci -c "=> write client hello" \ 3048a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3049a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3050a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3051a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3052a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3053a8e1175bSopenharmony_ci -c "<= write client hello" \ 3054a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3055a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3056a8e1175bSopenharmony_ci 3057a8e1175bSopenharmony_ci#GNUTLS-SERVER ephemeral mode 3058a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3059a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3060a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3061a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3062a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3063a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 3064a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: ephemeral/all, good" \ 3065a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK --pskpasswd=data_files/simplepass.psk" \ 3066a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 3067a8e1175bSopenharmony_ci 0 \ 3068a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 3069a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3070a8e1175bSopenharmony_ci 3071a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3072a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3073a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3074a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3075a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3076a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 3077a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: ephemeral/ephemeral_all, good" \ 3078a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK --pskpasswd=data_files/simplepass.psk" \ 3079a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral" \ 3080a8e1175bSopenharmony_ci 0 \ 3081a8e1175bSopenharmony_ci -c "Selected key exchange mode: ephemeral" \ 3082a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3083a8e1175bSopenharmony_ci 3084a8e1175bSopenharmony_ci#GNUTLS-SERVER ephemeral_all mode 3085a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3086a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3087a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3088a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3089a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3090a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 3091a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3092a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: ephemeral_all/all, good" \ 3093a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK --pskpasswd=data_files/simplepass.psk" \ 3094a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 3095a8e1175bSopenharmony_ci 0 \ 3096a8e1175bSopenharmony_ci -c "=> write client hello" \ 3097a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3098a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3099a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3100a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3101a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3102a8e1175bSopenharmony_ci -c "<= write client hello" \ 3103a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3104a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3105a8e1175bSopenharmony_ci 3106a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3107a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3108a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3109a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3110a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3111a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 3112a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3113a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: ephemeral_all/ephemeral_all, good" \ 3114a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK --pskpasswd=data_files/simplepass.psk" \ 3115a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=ephemeral_all" \ 3116a8e1175bSopenharmony_ci 0 \ 3117a8e1175bSopenharmony_ci -c "=> write client hello" \ 3118a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3119a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3120a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3121a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3122a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3123a8e1175bSopenharmony_ci -c "<= write client hello" \ 3124a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3125a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3126a8e1175bSopenharmony_ci 3127a8e1175bSopenharmony_ci#GNUTLS-SERVER all mode 3128a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3129a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3130a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3131a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3132a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3133a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 3134a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 3135a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3136a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: all/all, good" \ 3137a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:+PSK --pskpasswd=data_files/simplepass.psk" \ 3138a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 3139a8e1175bSopenharmony_ci 0 \ 3140a8e1175bSopenharmony_ci -c "=> write client hello" \ 3141a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3142a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3143a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3144a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3145a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3146a8e1175bSopenharmony_ci -c "<= write client hello" \ 3147a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3148a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3149a8e1175bSopenharmony_ci 3150a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3 3151a8e1175bSopenharmony_cirequires_gnutls_tls1_3 3152a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE 3153a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_DEBUG_C 3154a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_CLI_C 3155a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED 3156a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED 3157a8e1175bSopenharmony_cirequires_config_enabled MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED 3158a8e1175bSopenharmony_cirun_test "TLS 1.3: m->G: all/ephemeral_all, good" \ 3159a8e1175bSopenharmony_ci "$G_NEXT_SRV -d 4 --priority=NORMAL:-VERS-ALL:+VERS-TLS1.3:-KX-ALL:+ECDHE-PSK:+DHE-PSK:-PSK --pskpasswd=data_files/simplepass.psk" \ 3160a8e1175bSopenharmony_ci "$P_CLI debug_level=4 psk=010203 psk_identity=0a0b0c tls13_kex_modes=all" \ 3161a8e1175bSopenharmony_ci 0 \ 3162a8e1175bSopenharmony_ci -c "=> write client hello" \ 3163a8e1175bSopenharmony_ci -c "client hello, adding pre_shared_key extension, omitting PSK binder list" \ 3164a8e1175bSopenharmony_ci -c "client hello, adding psk_key_exchange_modes extension" \ 3165a8e1175bSopenharmony_ci -c "client hello, adding PSK binder list" \ 3166a8e1175bSopenharmony_ci -s "Parsing extension 'PSK Key Exchange Modes/45'" \ 3167a8e1175bSopenharmony_ci -s "Parsing extension 'Pre Shared Key/41'" \ 3168a8e1175bSopenharmony_ci -c "<= write client hello" \ 3169a8e1175bSopenharmony_ci -c "Selected key exchange mode: psk_ephemeral" \ 3170a8e1175bSopenharmony_ci -c "HTTP/1.0 200 OK" 3171