[2/7] test/crypto: add combined mode cases for TLS 1.3

Message ID 20240617055841.2359729-3-asasidharan@marvell.com (mailing list archive)
State Superseded
Delegated to: akhil goyal
Headers
Series Improvements and new test cases |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Aakash Sasidharan June 17, 2024, 5:58 a.m. UTC
  Add cases to try TLS 1.3 record write(encrypt) + read(decrypt)
operations. This is used for testing TLS 1.3 record features with
all algorithms supported by the security device.

Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
---
 app/test/test_cryptodev.c | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)
  

Patch

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index 61ee43327a..c5244db883 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -12680,6 +12680,19 @@  test_dtls_1_2_record_proto_sg_opt_padding_max(void)
 	return test_tls_record_proto_opt_padding(33, 4, RTE_SECURITY_VERSION_DTLS_1_2);
 }
 
+static int
+test_tls_1_3_record_proto_display_list(void)
+{
+	struct tls_record_test_flags flags;
+
+	memset(&flags, 0, sizeof(flags));
+
+	flags.display_alg = true;
+	flags.tls_version = RTE_SECURITY_VERSION_TLS_1_3;
+
+	return test_tls_record_proto_all(&flags);
+}
+
 static int
 test_tls_1_3_record_proto_corrupt_pkt(void)
 {
@@ -18199,6 +18212,10 @@  static struct unit_test_suite tls13_record_proto_testsuite  = {
 			"TLS-1.3 record SG mode with optional padding",
 			ut_setup_security, ut_teardown,
 			test_tls_1_3_record_proto_sg_opt_padding_1),
+		TEST_CASE_NAMED_ST(
+			"Combined test alg list",
+			ut_setup_security, ut_teardown,
+			test_tls_1_3_record_proto_display_list),
 		TEST_CASES_END() /**< NULL terminate unit test array */
 	}
 };