Skip to content

Commit 6183a64

Browse files
Normalize requirements in defragmentation test cases
Be more uniform in where certificate authentication and ECDSA are explicitly required. A few test cases now run in PSK-only configurations where they always could. Add a missing requirement on ECDSA to test cases that are currently skipped. Signed-off-by: Gilles Peskine <[email protected]>
1 parent 49e1ed2 commit 6183a64

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

tests/opt-testcases/handshake-manual.sh

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# To guarantee that the handhake messages are large enough and need to be split
22
# into fragments, the tests require certificate authentication. The party in control
33
# of the fragmentation operations is OpenSSL and will always use server5.crt (548 Bytes).
4-
requires_certificate_authentication
54
run_test "Handshake defragmentation on client: no fragmentation, for reference" \
65
"$O_NEXT_SRV" \
76
"$P_CLI debug_level=4" \
@@ -182,6 +181,7 @@ run_test "Handshake defragmentation on client: len=13, TLS 1.3" \
182181
skip_next_test
183182
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
184183
requires_certificate_authentication
184+
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
185185
run_test "Handshake defragmentation on client: len=13, TLS 1.2" \
186186
"$O_NEXT_SRV -tls1_2 -split_send_frag 13" \
187187
"$P_CLI debug_level=4" \
@@ -203,6 +203,7 @@ run_test "Handshake defragmentation on client: len=5, TLS 1.3" \
203203
skip_next_test
204204
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
205205
requires_certificate_authentication
206+
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
206207
run_test "Handshake defragmentation on client: len=5, TLS 1.2" \
207208
"$O_NEXT_SRV -tls1_2 -split_send_frag 5" \
208209
"$P_CLI debug_level=4" \
@@ -224,6 +225,7 @@ run_test "Handshake defragmentation on client: len=4, TLS 1.3" \
224225
skip_next_test
225226
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
226227
requires_certificate_authentication
228+
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
227229
run_test "Handshake defragmentation on client: len=4, TLS 1.2" \
228230
"$O_NEXT_SRV -tls1_2 -split_send_frag 4" \
229231
"$P_CLI debug_level=4" \
@@ -233,7 +235,6 @@ run_test "Handshake defragmentation on client: len=4, TLS 1.2" \
233235
-c "waiting for more fragments (4 of"
234236

235237
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
236-
requires_certificate_authentication
237238
run_test "Handshake defragmentation on client: len=3, TLS 1.3" \
238239
"$O_NEXT_SRV -tls1_3 -split_send_frag 3" \
239240
"$P_CLI debug_level=4" \
@@ -250,7 +251,6 @@ run_test "Handshake defragmentation on client: len=3, TLS 1.2" \
250251
-c "handshake message too short: 3" \
251252
-c "SSL - An invalid SSL record was received"
252253

253-
requires_certificate_authentication
254254
run_test "Handshake defragmentation on server: no fragmentation, for reference" \
255255
"$P_SRV debug_level=4 auth_mode=required" \
256256
"$O_NEXT_CLI -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
@@ -489,7 +489,6 @@ run_test "Handshake defragmentation on server: len=4, TLS 1.2 TLS 1.3 Client
489489
-s "waiting for more fragments (4 of"
490490

491491
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
492-
requires_certificate_authentication
493492
run_test "Handshake defragmentation on server: len=3, TLS 1.3" \
494493
"$P_SRV debug_level=4 auth_mode=required" \
495494
"$O_NEXT_CLI -tls1_3 -split_send_frag 3 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
@@ -500,7 +499,6 @@ run_test "Handshake defragmentation on server: len=3, TLS 1.3" \
500499

501500
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
502501
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
503-
requires_certificate_authentication
504502
run_test "Handshake defragmentation on server: len=3, TLS 1.2 TLS 1.3 ClientHello -> 1.2 Handshake" \
505503
"$P_SRV debug_level=4 auth_mode=required" \
506504
"$O_NEXT_CLI -tls1_2 -split_send_frag 3 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \

0 commit comments

Comments
 (0)