Skip to contentSkip to conversation

support SSL/TLS way of cipher-auth operations

PATCH Superseded Tejasree Kondoj 6 participants 14 messages Dec 18, 2020 – Jan 27, 2021 Crypto API

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

cover support SSL/TLS way of cipher-auth operations

This series adds SSL/TLS way of cipher-auth operations support i.e. auth generation followed by encryption and decryption followed by auth verify in OCTEON TX, OCTEON TX2 PMDs and sample unit test application.

Tejasree Kondoj (2):
common/cpt: support SSL/TLS way of cipher-auth operations test/crypto: support SSL/TLS way of cipher-auth operations

 app/test/test_cryptodev_aes_test_vectors.h    | 576 ++++++++++++++++++
 app/test/test_cryptodev_blockcipher.c         |  98 ++-
 app/test/test_cryptodev_blockcipher.h         |   9 +
 doc/guides/rel_notes/release_21_02.rst        |  12 +
 drivers/common/cpt/cpt_mcode_defines.h        |   7 +-
 drivers/common/cpt/cpt_ucode.h                |  42 +-
 drivers/crypto/octeontx/otx_cryptodev_ops.c   |   8 +-
 drivers/crypto/octeontx2/otx2_cryptodev_ops.c |   8 +-
 8 files changed, 736 insertions(+), 24 deletions(-)
Signature · 1 line
2.27.0
#1 lore raw

PATCH 1/2 common/cpt: support SSL/TLS way of cipher-auth operations

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---
 doc/guides/rel_notes/release_21_02.rst        |  6 +++
 drivers/common/cpt/cpt_mcode_defines.h        |  7 +++-
 drivers/common/cpt/cpt_ucode.h                | 42 +++++++++++++++----
 drivers/crypto/octeontx/otx_cryptodev_ops.c   |  8 +++-
 drivers/crypto/octeontx2/otx2_cryptodev_ops.c |  8 +++-
 5 files changed, 59 insertions(+), 12 deletions(-)
doc/guides/rel_notes/release_21_02.rst +6 -0
index 638f98168b..d1d4b25665 100644
@@ -55,6 +55,12 @@ New Features
      Also, make sure to start the actual text at the margin.
      =======================================================
 
+* **Updated OCTEON TX and OCTEON TX2 crypto PMDs.**
+
+  * Added SSL/TLS way of cipher-auth operations support i.e. auth generation
+    followed by encryption and decryption followed by auth verify in OCTEONT TX
+    and OCTEON TX2 crypto PMDs.
+
 
 Removed Items
 -------------
drivers/common/cpt/cpt_mcode_defines.h +6 -1
index 56a745f419..624bdcf3cf 100644
@@ -20,6 +20,9 @@
 #define CPT_MAJOR_OP_ZUC_SNOW3G	0x37
 #define CPT_MAJOR_OP_KASUMI	0x38
 #define CPT_MAJOR_OP_MISC	0x01
+#define CPT_HMAC_FIRST_BIT_POS	0x4
+#define CPT_FC_MINOR_OP_ENCRYPT	0x0
+#define CPT_FC_MINOR_OP_DECRYPT	0x1
 
 /* AE opcodes */
 #define CPT_MAJOR_OP_MODEX	0x03
@@ -314,8 +317,10 @@ struct cpt_ctx {
 	uint64_t hmac		:1;
 	uint64_t zsk_flags	:3;
 	uint64_t k_ecb		:1;
+	uint64_t auth_enc	:1;
+	uint64_t dec_auth	:1;
 	uint64_t snow3g		:2;
-	uint64_t rsvd		:21;
+	uint64_t rsvd		:19;
 	/* Below fields are accessed by hardware */
 	union {
 		mc_fc_context_t fctx;
drivers/common/cpt/cpt_ucode.h +35 -7

108 lines not on this page · raw message

drivers/crypto/octeontx/otx_cryptodev_ops.c +6 -2
index 0cf760b296..af7a1f64f8 100644
@@ -205,12 +205,16 @@ sym_xform_verify(struct rte_crypto_sym_xform *xform)
 	if (xform->next) {
 		if (xform->type == RTE_CRYPTO_SYM_XFORM_AUTH &&
 		    xform->next->type == RTE_CRYPTO_SYM_XFORM_CIPHER &&
-		    xform->next->cipher.op == RTE_CRYPTO_CIPHER_OP_ENCRYPT)
+		    xform->next->cipher.op == RTE_CRYPTO_CIPHER_OP_ENCRYPT &&
+		    (xform->auth.algo != RTE_CRYPTO_AUTH_SHA1_HMAC ||
+		     xform->next->cipher.algo != RTE_CRYPTO_CIPHER_AES_CBC))
 			return -ENOTSUP;
 
 		if (xform->type == RTE_CRYPTO_SYM_XFORM_CIPHER &&
 		    xform->cipher.op == RTE_CRYPTO_CIPHER_OP_DECRYPT &&
-		    xform->next->type == RTE_CRYPTO_SYM_XFORM_AUTH)
+		    xform->next->type == RTE_CRYPTO_SYM_XFORM_AUTH &&
+		    (xform->cipher.algo != RTE_CRYPTO_CIPHER_AES_CBC ||
+		     xform->next->auth.algo != RTE_CRYPTO_AUTH_SHA1_HMAC))
 			return -ENOTSUP;
 
 		if (xform->type == RTE_CRYPTO_SYM_XFORM_CIPHER &&
drivers/crypto/octeontx2/otx2_cryptodev_ops.c +6 -2
index 5f2ccc0872..5511739663 100644
@@ -320,12 +320,16 @@ sym_xform_verify(struct rte_crypto_sym_xform *xform)
 	if (xform->next) {
 		if (xform->type == RTE_CRYPTO_SYM_XFORM_AUTH &&
 		    xform->next->type == RTE_CRYPTO_SYM_XFORM_CIPHER &&
-		    xform->next->cipher.op == RTE_CRYPTO_CIPHER_OP_ENCRYPT)
+		    xform->next->cipher.op == RTE_CRYPTO_CIPHER_OP_ENCRYPT &&
+		    (xform->auth.algo != RTE_CRYPTO_AUTH_SHA1_HMAC ||
+		     xform->next->cipher.algo != RTE_CRYPTO_CIPHER_AES_CBC))
 			return -ENOTSUP;
 
 		if (xform->type == RTE_CRYPTO_SYM_XFORM_CIPHER &&
 		    xform->cipher.op == RTE_CRYPTO_CIPHER_OP_DECRYPT &&
-		    xform->next->type == RTE_CRYPTO_SYM_XFORM_AUTH)
+		    xform->next->type == RTE_CRYPTO_SYM_XFORM_AUTH &&
+		    (xform->cipher.algo != RTE_CRYPTO_CIPHER_AES_CBC ||
+		     xform->next->auth.algo != RTE_CRYPTO_AUTH_SHA1_HMAC))
 			return -ENOTSUP;
 
 		if (xform->type == RTE_CRYPTO_SYM_XFORM_CIPHER &&
Signature · 1 line
2.27.0
#2 lore raw

PATCH 2/2 test/crypto: support SSL/TLS way of cipher-auth operations

In reply to Tejasree Kondoj

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---
 app/test/test_cryptodev_aes_test_vectors.h | 576 +++++++++++++++++++++
 app/test/test_cryptodev_blockcipher.c      |  98 +++-
 app/test/test_cryptodev_blockcipher.h      |   9 +
 doc/guides/rel_notes/release_21_02.rst     |   6 +
 4 files changed, 677 insertions(+), 12 deletions(-)
app/test/test_cryptodev_aes_test_vectors.h +576 -0
index c192d75a7e..c239c1cb35 100644
@@ -1093,6 +1093,172 @@ static const uint8_t ciphertext512_aes128cbc_aad[] = {
 	0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75
 };
 
+static const uint8_t plaintext_aes_common_ssl[] = {
+	0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+	0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+	0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+	0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+	0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+	0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+	0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+	0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+	0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+	0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+	0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+	0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+	0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+	0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+	0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+	0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+	0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
+	0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+	0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+	0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+	0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+	0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+	0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+	0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+	0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+	0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+	0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+	0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+	0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+	0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+	0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+	0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+	0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+	0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+	0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+	0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+	0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+	0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+	0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+	0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+	0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+	0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+	0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+	0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+	0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+	0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+	0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+	0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+	0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+	0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+	0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+	0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+	0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+	0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+	0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+	0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+	0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+	0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+	0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+	0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+	0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+	0x20, 0x77, 0x69, 0x6E, 0x6E, 0x65, 0x72, 0x73,
+	0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x6c, 0x6f,
+	0x73, 0x65, 0x72, 0x73, 0x2c, 0x20, 0x73, 0x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,
+	0x95, 0xBB, 0x26, 0x74, 0x69, 0x12, 0x7F, 0xF1,
+	0xBB, 0xFF, 0xAE, 0xB5, 0x99, 0x6E, 0xCB, 0x0C,
+	/* encrypted mac */
+	0x39, 0x34, 0x16, 0x84, 0xE7, 0x90, 0x02, 0xB1,
+	0x3E, 0x92, 0xCB, 0x58, 0x98, 0xBA, 0x7C, 0x98,
+	0x8B, 0x90, 0xFB, 0x5E, 0x9D, 0x74, 0xCC, 0x56,
+	0xE3, 0x55, 0xB1, 0xC8, 0xC8, 0x7C, 0xB2, 0xE7
+};
+
+static const uint8_t plaintext_aes_common_short_ssl[] = {
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD
+};
+
+static const uint8_t ciphertext512_aes128cbc_short_ssl[] = {
+	0x6D, 0xB1, 0x23, 0x86, 0x58, 0x54, 0x83, 0xE7,
+	0x3B, 0x27, 0x85, 0xA7, 0x06, 0xBC, 0x4A, 0xFB,
+	0x16, 0xD8, 0x56, 0x7C, 0x39, 0xC6, 0xE7, 0x1A,
+	0x67, 0xA8, 0x48, 0x22, 0xD6, 0xFF, 0x96, 0xB3,
+	0xA1, 0x52, 0x52, 0x83, 0xE6, 0x2E, 0x6A, 0xC9,
+	0x57, 0x8E, 0x34, 0x6F, 0xEE, 0x41, 0xF5, 0xBD,
+	0x6B, 0x89, 0x31, 0x64, 0x89, 0xAB, 0xDE, 0xA7,
+	0xBD, 0xFD, 0x46, 0x40, 0xE7, 0x13, 0x23, 0x84,
+	0xDD, 0xCB, 0x35, 0x87, 0x4E, 0x57, 0xB7, 0x97,
+	0x9E, 0xAB, 0xFB, 0xE7, 0x18, 0x82, 0x05, 0xDF
+};
+
 /* AES128-CTR-SHA1 test vector */
 static const struct blockcipher_test_data aes_test_data_1 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CTR,
@@ -1409,6 +1575,50 @@ static const struct blockcipher_test_data aes_test_data_4 = {
 	}
 };
 
+/** AES-128-CBC SHA1 test vector (SSL/TLS order) */
+static const struct blockcipher_test_data aes_test_data_4_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A
+		},
+		.len = 16
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes128cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 /** AES-128-CBC SHA256 test vector */
 static const struct blockcipher_test_data aes_test_data_5 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
@@ -1733,6 +1943,77 @@ static const uint8_t ciphertext512_aes192cbc[] = {
 	0x4F, 0x2F, 0x50, 0xE2, 0x77, 0x62, 0xD9, 0xCC
 };
 
+static const uint8_t ciphertext512_aes192cbc_ssl[] = {
+	0x45, 0xee, 0x9a, 0xEA, 0x3C, 0x03, 0xFC, 0x4C,
+	0x84, 0x36, 0xB0, 0xDA, 0xB0, 0xDC, 0xF3, 0x5B,
+	0x75, 0xA7, 0xBE, 0x0E, 0xC0, 0x8D, 0x6C, 0xF8,
+	0xC1, 0x0F, 0xD0, 0x35, 0x1D, 0x82, 0xAE, 0x7C,
+	0x57, 0xC5, 0x7A, 0x55, 0x87, 0x1B, 0xD4, 0x03,
+	0x0A, 0x64, 0xC9, 0xE0, 0xF4, 0xC7, 0x6F, 0x57,
+	0x52, 0xC6, 0x73, 0xBA, 0x84, 0x0B, 0x5B, 0x89,
+	0x21, 0xD2, 0x9B, 0x88, 0x68, 0xF5, 0xA9, 0x7F,
+	0x3F, 0x49, 0xEB, 0xF4, 0xD4, 0x52, 0xD2, 0x64,
+	0x80, 0xB2, 0x53, 0xDA, 0x19, 0xF6, 0x10, 0x24,
+	0x23, 0x26, 0x7A, 0x7C, 0x07, 0x57, 0x4B, 0x0E,
+	0x58, 0x49, 0x61, 0xD1, 0xDC, 0x9A, 0x32, 0x6B,
+	0x0F, 0x43, 0x9E, 0x4D, 0xB4, 0x07, 0x4E, 0xB3,
+	0x51, 0x74, 0xDE, 0x29, 0xBC, 0x98, 0xF9, 0xDF,
+	0x78, 0x9A, 0x18, 0x9C, 0xD6, 0x7A, 0x55, 0x7C,
+	0xE6, 0x1D, 0x5C, 0x1A, 0x99, 0xD2, 0xC3, 0x7B,
+	0x9F, 0x96, 0x74, 0x2D, 0xE0, 0xEF, 0xD1, 0xE3,
+	0x08, 0x9F, 0xA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,
+	0x0F, 0xAE, 0xA6, 0xC2, 0xE5, 0x8F, 0x45, 0xB2,
+	0x85, 0x99, 0x02, 0xA2, 0x9B, 0xBE, 0x90, 0x43,
+	0x4F, 0x2F, 0x50, 0xE2, 0x77, 0x62, 0xD9, 0xCC,
+	0x5D, 0x93, 0x6A, 0x97, 0xFB, 0x1D, 0x01, 0x17,
+	0x90, 0x61, 0x41, 0xD5, 0x5C, 0x43, 0x60, 0xBC,
+	0x21, 0x04, 0x5B, 0xB9, 0xFF, 0x75, 0xF8, 0x1F,
+	0x5C, 0x85, 0x91, 0x08, 0x02, 0xA2, 0xFD, 0x88,
+};
+
 /** AES-192-CBC test vector */
 static const struct blockcipher_test_data aes_test_data_10 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
@@ -1761,6 +2042,51 @@ static const struct blockcipher_test_data aes_test_data_10 = {
 	}
 };
 
+/** AES-192-CBC SHA1 test vector (SSL/TLS order) */
+static const struct blockcipher_test_data aes_test_data_10_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A,
+			0xD4, 0xC3, 0xA3, 0xAA, 0x33, 0x62, 0x61, 0xE0
+		},
+		.len = 24
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes192cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 static const uint8_t ciphertext512_aes256cbc[] = {
 	0xF3, 0xDD, 0xF0, 0x0B, 0xFF, 0xA2, 0x6A, 0x04,
 	0xBE, 0xDA, 0x52, 0xA6, 0xFE, 0x6B, 0xA6, 0xA7,
@@ -1828,6 +2154,77 @@ static const uint8_t ciphertext512_aes256cbc[] = {
 	0xB7, 0x1C, 0x6D, 0xF2, 0xAE, 0x79, 0xA4, 0x7C
 };
 
+static const uint8_t ciphertext512_aes256cbc_ssl[] = {
+	0xF3, 0xDD, 0xF0, 0x0B, 0xFF, 0xA2, 0x6A, 0x04,
+	0xBE, 0xDA, 0x52, 0xA6, 0xFE, 0x6B, 0xA6, 0xA7,
+	0x48, 0x1D, 0x7D, 0x98, 0x65, 0xDB, 0xEF, 0x06,
+	0x26, 0xB5, 0x8E, 0xEB, 0x05, 0x0E, 0x77, 0x98,
+	0x17, 0x8E, 0xD0, 0xD4, 0x7B, 0x92, 0x8F, 0x5C,
+	0xD0, 0x74, 0x5C, 0xA8, 0x4B, 0x54, 0xB6, 0x2F,
+	0x83, 0x72, 0x2C, 0xFF, 0x72, 0xE9, 0xE4, 0x15,
+	0x4C, 0x32, 0xAF, 0xC8, 0xC9, 0x89, 0x3C, 0x6E,
+	0x31, 0xD5, 0xC0, 0x16, 0xC0, 0x31, 0x7D, 0x11,
+	0xAB, 0xCB, 0xDE, 0xD2, 0xD6, 0xAA, 0x76, 0x5E,
+	0xBA, 0xF6, 0xE2, 0x92, 0xCB, 0x86, 0x07, 0xF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, 0xEB, 0xD9, 0x23,
+	0xE3, 0x86, 0xFB, 0xD7, 0x48, 0x76, 0x9D, 0xE3,
+	0x89, 0x87, 0x39, 0xFA, 0x7B, 0x21, 0x0B, 0x76,
+	0xB2, 0xED, 0x1C, 0x27, 0x4B, 0xD5, 0x27, 0x05,
+	0x8C, 0x7D, 0x58, 0x6C, 0xCA, 0xA5, 0x54, 0x9A,
+	0x0F, 0xCB, 0xE9, 0x88, 0x31, 0xAD, 0x49, 0xEE,
+	0x38, 0xFB, 0xC9, 0xFB, 0xB4, 0x7A, 0x00, 0x58,
+	0x20, 0x32, 0xD3, 0x53, 0x5A, 0xDD, 0x74, 0x95,
+	0x60, 0x59, 0x09, 0xAE, 0x7E, 0xEC, 0x74, 0xA3,
+	0xB7, 0x1C, 0x6D, 0xF2, 0xAE, 0x79, 0xA4, 0x7C,
+	0x50, 0xB1, 0x8D, 0x56, 0x22, 0x75, 0xD6, 0x8F,
+	0x93, 0xB5, 0xED, 0xE8, 0x3D, 0x20, 0x4F, 0x9F,
+	0x80, 0x2F, 0x56, 0x95, 0xA0, 0x80, 0xC6, 0xC2,
+	0xA8, 0x27, 0xFB, 0x48, 0x96, 0x58, 0xA1, 0x93,
+};
+
 /** AES-256-CBC test vector */
 static const struct blockcipher_test_data aes_test_data_11 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
@@ -1857,6 +2254,52 @@ static const struct blockcipher_test_data aes_test_data_11 = {
 	}
 };
 
+/** AES-256-CBC SHA1 test vector (SSL/TLS order) */
+static const struct blockcipher_test_data aes_test_data_11_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A,
+			0xD4, 0xC3, 0xA3, 0xAA, 0x33, 0x62, 0x61, 0xE0,
+			0x37, 0x07, 0xB8, 0x23, 0xA2, 0xA3, 0xB5, 0x8D
+		},
+		.len = 32
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes256cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 /** AES-128-CBC SHA256 HMAC test vector (160 bytes) */
 static const struct blockcipher_test_data aes_test_data_12 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
@@ -1949,6 +2392,50 @@ static const struct blockcipher_test_data aes_test_data_13 = {
 	}
 };
 
+/** AES-128-CBC SHA1 test vector (SSL/TLS order) */
+static const struct blockcipher_test_data aes_test_data_13_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A
+		},
+		.len = 16
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_short_ssl,
+		.len = 50
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes128cbc_short_ssl,
+		.len = 50
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA,
+			0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA,
+			0xAA, 0xAA, 0xAA, 0xAA
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x12, 0x5D, 0x73, 0x42, 0xB9, 0xAC, 0x11, 0xCD,
+			0x91, 0xA3, 0x9A, 0xF4, 0x8A, 0xA1, 0x7B, 0x4F,
+			0x63, 0xF1, 0x75, 0xD3
+		},
+		.len = 20,
+	}
+};
+
 /** XTS-AES-128 test vector (2 keys * 128 bit) */
 static const uint8_t plaintext_aes128xts_16bytes[] = {
 	0xEB, 0xAB, 0xCE, 0x95, 0xB1, 0x4D, 0x3C, 0x8D,
@@ -2886,6 +3373,95 @@ static const struct blockcipher_test_case aes_cipheronly_test_cases[] = {
 		.test_data = &aes_test_data_21,
 		.op_mask = BLOCKCIPHER_TEST_OP_DECRYPT,
 	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest"
+			"(SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"(short buffers) (SSL/TLS order)",
+		.test_data = &aes_test_data_13_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-192-CBC HMAC-SHA1 Encryption Digest "
+			"Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_10_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-256-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_11_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG |
+			BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify (short buffers) (SSL/TLS order)",
+		.test_data = &aes_test_data_13_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-256-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_11_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-192-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_10_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS |
+				BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	}
 };
 
 static const struct blockcipher_test_case aes_docsis_test_cases[] = {
app/test/test_cryptodev_blockcipher.c +86 -12

162 lines not on this page · raw message

app/test/test_cryptodev_blockcipher.h +9 -0
index 8990716844..c72cfe5342 100644
@@ -13,6 +13,7 @@
 #define BLOCKCIPHER_TEST_OP_DECRYPT		0x02
 #define BLOCKCIPHER_TEST_OP_AUTH_GEN	0x04
 #define BLOCKCIPHER_TEST_OP_AUTH_VERIFY	0x08
+#define BLOCKCIPHER_TEST_OP_SSL_ORDER	0x10
 
 #define BLOCKCIPHER_TEST_FEATURE_OOP			0x01
 #define BLOCKCIPHER_TEST_FEATURE_SESSIONLESS	0x02
@@ -31,6 +32,14 @@
 #define BLOCKCIPHER_TEST_OP_AUTH_VERIFY_DEC	(BLOCKCIPHER_TEST_OP_DECRYPT | \
 					BLOCKCIPHER_TEST_OP_AUTH_VERIFY)
 
+#define BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC	(BLOCKCIPHER_TEST_OP_ENCRYPT | \
+					BLOCKCIPHER_TEST_OP_AUTH_GEN | \
+					BLOCKCIPHER_TEST_OP_SSL_ORDER)
+
+#define BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY	(BLOCKCIPHER_TEST_OP_DECRYPT | \
+					BLOCKCIPHER_TEST_OP_AUTH_VERIFY | \
+					BLOCKCIPHER_TEST_OP_SSL_ORDER)
+
 enum blockcipher_test_type {
 	BLKCIPHER_AES_CHAIN_TYPE,	/* use aes_chain_test_cases[] */
 	BLKCIPHER_AES_CIPHERONLY_TYPE,	/* use aes_cipheronly_test_cases[] */
doc/guides/rel_notes/release_21_02.rst +6 -0
index d1d4b25665..eb2d4ab2d9 100644
@@ -61,6 +61,12 @@ New Features
     followed by encryption and decryption followed by auth verify in OCTEONT TX
     and OCTEON TX2 crypto PMDs.
 
+* **Updated unit test sample application.**
+
+  * Added SSL/TLS way of cipher-auth operations support i.e. auth generation
+    followed by encryption and decryption followed by auth verify in sample
+    unit test application.
+
 
 Removed Items
 -------------
Signature · 1 line
2.27.0
#10 lore raw
In reply to Tejasree Kondoj
Quoted 9 lines

This series adds SSL/TLS way of cipher-auth operations support i.e. auth generation followed by encryption and decryption followed by auth verify in OCTEON TX, OCTEON TX2 PMDs and sample unit test application.

Tejasree Kondoj (2):
common/cpt: support SSL/TLS way of cipher-auth operations test/crypto: support SSL/TLS way of cipher-auth operations

Quoted 11 lines
 app/test/test_cryptodev_aes_test_vectors.h    | 576
++++++++++++++++++
 app/test/test_cryptodev_blockcipher.c         |  98 ++-
 app/test/test_cryptodev_blockcipher.h         |   9 +
 doc/guides/rel_notes/release_21_02.rst        |  12 +
 drivers/common/cpt/cpt_mcode_defines.h        |   7 +-
 drivers/common/cpt/cpt_ucode.h                |  42 +-
 drivers/crypto/octeontx/otx_cryptodev_ops.c   |   8 +-
 drivers/crypto/octeontx2/otx2_cryptodev_ops.c |   8 +-
 8 files changed, 736 insertions(+), 24 deletions(-)

Series Acked-by: Anoob Joseph <[email protected]>

#4 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

In reply to Akhil Goyal
Quoted 13 lines · Akhil Goyal

Hi Tejasree,

Quoted 8 lines

Subject: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---

With this patch the following existing case is failing on NXP platforms. Please check.

Quoted 9 lines

10) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather line 634 FAILED: Generated digest data not as expected

Fiona/Fan,
Could you please check this patch on intel platform?

Regards,
Akhil

Hey Akhil, we'll check it out and let you know tomorrow.

#3 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

In reply to Tejasree Kondoj

Hi Tejasree,

Quoted 8 lines

Subject: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---

With this patch the following existing case is failing on NXP platforms. Please check.

10) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather line 634 FAILED: Generated digest data not as expected

Fiona/Fan,
Could you please check this patch on intel platform?

Regards,
Akhil

#5 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Hi Akhil and Tejasree,

Yes it failed at RAW API tests

RTE>>cryptodev_qat_raw_api_autotest
...
49) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest(SSL/TLS order) line 619 FAILED: Crypto data not as expected
50) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather (SSL/TLS order) line 619 FAILED: Crypto data not as expected
51) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest (short buffers) (SSL/TLS order) line 619 FAILED: Crypto data not as expected
52) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather (SSL/TLS order) line 619 FAILED: Crypto data not as expected
Device doesn't support sessionless operations Test Skipped.
53) TestCase AES-192-CBC HMAC-SHA1 Encryption Digest Sessionless (SSL/TLS order) SKIPPED
Device doesn't support sessionless operations Test Skipped.
54) TestCase AES-256-CBC HMAC-SHA1 Encryption Digest Scatter Gather Sessionless (SSL/TLS order) SKIPPED
55) TestCase AES-128-CBC HMAC-SHA1 Decryption Digest Verify (SSL/TLS order) line 591 FAILED: Operation failed (0x5)
56) TestCase AES-128-CBC HMAC-SHA1 Decryption Digest Verify Scatter Gather (SSL/TLS order) line 591 FAILED: Operation failed (0x5)
57) TestCase AES-128-CBC HMAC-SHA1 Decryption Digest Verify (short buffers) (SSL/TLS order) line 591 FAILED: Operation failed (0x5)
58) TestCase AES-128-CBC HMAC-SHA1 Decryption Digest Verify Scatter Gather (SSL/TLS order) line 591 FAILED: Operation failed (0x5)
Device doesn't support sessionless operations Test Skipped.
59) TestCase AES-256-CBC HMAC-SHA1 Decryption Digest Verify Sessionless (SSL/TLS order) SKIPPED
Device doesn't support sessionless operations Test Skipped.
60) TestCase AES-192-CBC HMAC-SHA1 Decryption Digest Verify Scatter Gather Sessionless (SSL/TLS order) SKIPPED
Device doesn't support sessionless operations Test Skipped.
61) TestCase AES-128-CBC HMAC-SHA1 Decryption Digest Verify Sessionless (SSL/TLS order) SKIPPED
EAL: Test assert test_blockcipher line 1937 failed: Test failed
+ TestCase [ 8] : test_AES_cipheronly_all failed

Looks like the " AES-128-CBC HMAC-SHA1 * (SSL/TLS order)" tests are in the wrong place as this is a cipher only test sub-suite but you are testing chained operation.

Regards,
Fan

Quoted 35 lines

-----Original Message-----
From: Akhil Goyal <[email protected]>
Sent: Tuesday, January 19, 2021 5:01 PM
To: Tejasree Kondoj <[email protected]>; Nicolau, Radu <[email protected]>; Trahe, Fiona <[email protected]>; Zhang, Roy Fan <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: RE: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Hi Tejasree,

Quoted 1 line

Subject: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth

operations

Quoted 7 lines

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---

With this patch the following existing case is failing on NXP platforms. Please check.

10) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather line
634 FAILED: Generated digest data not as expected

Fiona/Fan,
Could you please check this patch on intel platform?

Regards,
Akhil

#6 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

In reply to Akhil Goyal

Hi Akhil,

I just did the check. QAT Raw API test did failed on newly added cases.
The patch needs to be updated - as all newly added tests are in aes_cipheronly_test_cases array, where clearly they are chained algorithm tests.

But the problem is not the only reason that causes the test fail - I will submit a QAT PMD fix patch for that.

Regards,
Fan

Quoted 35 lines

-----Original Message-----
From: Akhil Goyal <[email protected]>
Sent: Tuesday, January 19, 2021 5:01 PM
To: Tejasree Kondoj <[email protected]>; Nicolau, Radu <[email protected]>; Trahe, Fiona <[email protected]>; Zhang, Roy Fan <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: RE: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Hi Tejasree,

Quoted 1 line

Subject: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth

operations

Quoted 7 lines

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---

With this patch the following existing case is failing on NXP platforms. Please check.

10) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather line
634 FAILED: Generated digest data not as expected

Fiona/Fan,
Could you please check this patch on intel platform?

Regards,
Akhil

#7 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Hi Akhil and Fan,

I'll send v2 moving SSL/TLS test cases to aes_chain_test_cases array.

Thanks
Tejasree

Quoted 63 lines

-----Original Message-----
From: Zhang, Roy Fan <[email protected]>
Sent: Wednesday, January 20, 2021 8:04 PM
To: Akhil Goyal <[email protected]>; Tejasree Kondoj <[email protected]>; Nicolau, Radu <[email protected]>; Trahe, Fiona <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [EXT] RE: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher- auth operations

External Email

----------------------------------------------------------------------
Hi Akhil,

I just did the check. QAT Raw API test did failed on newly added cases. The patch needs to be updated - as all newly added tests are in aes_cipheronly_test_cases array, where clearly they are chained algorithm tests.

But the problem is not the only reason that causes the test fail - I will submit a QAT PMD fix patch for that.

Regards,
Fan

Quoted 36 lines

-----Original Message-----
From: Akhil Goyal <[email protected]>
Sent: Tuesday, January 19, 2021 5:01 PM
To: Tejasree Kondoj <[email protected]>; Nicolau, Radu <[email protected]>; Trahe, Fiona <[email protected]>; Zhang, Roy Fan <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: RE: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Hi Tejasree,

Quoted 1 line

Subject: [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth

operations

Quoted 7 lines

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---

With this patch the following existing case is failing on NXP platforms. Please check.

10) TestCase AES-128-CBC HMAC-SHA1 Encryption Digest Scatter Gather
line
634 FAILED: Generated digest data not as expected

Fiona/Fan,
Could you please check this patch on intel platform?

Regards,
Akhil

#11 lore raw
In reply to Tejasree Kondoj

Hi Akhil,

I'm planning to add device feature flag(RTE_CRYPTODEV_FF_SSL_ORDER) along with SSL test cases movement to chain array in v2. Would that be fine? Feature flag is needed to skip SSL test cases if device doesn't support them.

Thanks
Tejasree

Quoted 30 lines

-----Original Message-----
From: Tejasree Kondoj <[email protected]>
Sent: Friday, December 18, 2020 7:40 PM
To: Akhil Goyal <[email protected]>; Radu Nicolau <[email protected]>
Cc: Tejasree Kondoj <[email protected]>; Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [PATCH 0/2] support SSL/TLS way of cipher-auth operations

This series adds SSL/TLS way of cipher-auth operations support i.e. auth generation followed by encryption and decryption followed by auth verify in OCTEON TX, OCTEON TX2 PMDs and sample unit test application.

Tejasree Kondoj (2):
common/cpt: support SSL/TLS way of cipher-auth operations test/crypto: support SSL/TLS way of cipher-auth operations

 app/test/test_cryptodev_aes_test_vectors.h    | 576 ++++++++++++++++++
 app/test/test_cryptodev_blockcipher.c         |  98 ++-
 app/test/test_cryptodev_blockcipher.h         |   9 +
 doc/guides/rel_notes/release_21_02.rst        |  12 +
 drivers/common/cpt/cpt_mcode_defines.h        |   7 +-
 drivers/common/cpt/cpt_ucode.h                |  42 +-
 drivers/crypto/octeontx/otx_cryptodev_ops.c   |   8 +-
 drivers/crypto/octeontx2/otx2_cryptodev_ops.c |   8 +-
 8 files changed, 736 insertions(+), 24 deletions(-)

--
2.27.0

#8 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

In reply to Tejasree Kondoj

Hi Tejasree,

Quoted 669 lines

-----Original Message-----
From: dev <[email protected]> On Behalf Of Tejasree Kondoj
Sent: piątek, 18 grudnia 2020 15:10
To: Akhil Goyal <[email protected]>; Nicolau, Radu <[email protected]>
Cc: Tejasree Kondoj <[email protected]>; Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---
 app/test/test_cryptodev_aes_test_vectors.h | 576 +++++++++++++++++++++
 app/test/test_cryptodev_blockcipher.c      |  98 +++-
 app/test/test_cryptodev_blockcipher.h      |   9 +
 doc/guides/rel_notes/release_21_02.rst     |   6 +
 4 files changed, 677 insertions(+), 12 deletions(-)
app/test/test_cryptodev_aes_test_vectors.h +164 -0
index c192d75a7e..c239c1cb35 100644
@@ -1093,6 +1093,172 @@ static const uint8_t
 ciphertext512_aes128cbc_aad[] = {
 	0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75  };
 
+static const uint8_t plaintext_aes_common_ssl[] = {
+	0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+	0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+	0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+	0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+	0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+	0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+	0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+	0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+	0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+	0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+	0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+	0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+	0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+	0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+	0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+	0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+	0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
+	0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+	0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+	0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+	0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+	0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+	0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+	0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+	0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+	0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+	0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+	0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+	0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+	0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+	0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+	0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+	0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+	0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+	0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+	0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+	0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+	0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+	0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+	0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+	0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+	0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+	0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+	0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+	0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+	0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+	0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+	0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+	0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+	0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+	0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+	0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+	0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+	0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+	0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+	0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+	0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+	0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+	0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+	0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+	0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+	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A, 0xA6, 0x46, 0x84, 0x2E, 0xF6,
+	0x4B, 0xDC, 0x9B, 0x8F, 0x9B, 0x8F, 0xEE, 0xB4,
+	0xAA, 0x3F, 0xEE, 0xC0, 0x37, 0x27, 0x76, 0xC7,
+	0x95, 0xBB, 0x26, 0x74, 0x69, 0x12, 0x7F, 0xF1,
+	0xBB, 0xFF, 0xAE, 0xB5, 0x99, 0x6E, 0xCB, 0x0C,
+	/* encrypted mac */
+	0x39, 0x34, 0x16, 0x84, 0xE7, 0x90, 0x02, 0xB1,
+	0x3E, 0x92, 0xCB, 0x58, 0x98, 0xBA, 0x7C, 0x98,
+	0x8B, 0x90, 0xFB, 0x5E, 0x9D, 0x74, 0xCC, 0x56,
+	0xE3, 0x55, 0xB1, 0xC8, 0xC8, 0x7C, 0xB2, 0xE7 };
+
+static const uint8_t plaintext_aes_common_short_ssl[] = {
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD
+};
+
+static const uint8_t ciphertext512_aes128cbc_short_ssl[] = {
+	0x6D, 0xB1, 0x23, 0x86, 0x58, 0x54, 0x83, 0xE7,
+	0x3B, 0x27, 0x85, 0xA7, 0x06, 0xBC, 0x4A, 0xFB,
+	0x16, 0xD8, 0x56, 0x7C, 0x39, 0xC6, 0xE7, 0x1A,
+	0x67, 0xA8, 0x48, 0x22, 0xD6, 0xFF, 0x96, 0xB3,
+	0xA1, 0x52, 0x52, 0x83, 0xE6, 0x2E, 0x6A, 0xC9,
+	0x57, 0x8E, 0x34, 0x6F, 0xEE, 0x41, 0xF5, 0xBD,
+	0x6B, 0x89, 0x31, 0x64, 0x89, 0xAB, 0xDE, 0xA7,
+	0xBD, 0xFD, 0x46, 0x40, 0xE7, 0x13, 0x23, 0x84,
+	0xDD, 0xCB, 0x35, 0x87, 0x4E, 0x57, 0xB7, 0x97,
+	0x9E, 0xAB, 0xFB, 0xE7, 0x18, 0x82, 0x05, 0xDF };
+
 /* AES128-CTR-SHA1 test vector */
 static const struct blockcipher_test_data aes_test_data_1 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CTR, @@ -1409,6 +1575,50

@@ static const struct blockcipher_test_data aes_test_data_4 = {

app/test/test_cryptodev_aes_test_vectors.h +44 -0
 	}
 };
 
+/** AES-128-CBC SHA1 test vector (SSL/TLS order) */ static const struct
+blockcipher_test_data aes_test_data_4_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A
+		},
+		.len = 16
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes128cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 /** AES-128-CBC SHA256 test vector */
 static const struct blockcipher_test_data aes_test_data_5 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1733,6 +1943,77

@@ static const uint8_t ciphertext512_aes192cbc[] = {

app/test/test_cryptodev_aes_test_vectors.h +70 -0
 	0x4F, 0x2F, 0x50, 0xE2, 0x77, 0x62, 0xD9, 0xCC  };
 
+static const uint8_t ciphertext512_aes192cbc_ssl[] = {
+	0x45, 0xee, 0x9a, 0xEA, 0x3C, 0x03, 0xFC, 0x4C,
+	0x84, 0x36, 0xB0, 0xDA, 0xB0, 0xDC, 0xF3, 0x5B,
+	0x75, 0xA7, 0xBE, 0x0E, 0xC0, 0x8D, 0x6C, 0xF8,
+	0xC1, 0x0F, 0xD0, 0x35, 0x1D, 0x82, 0xAE, 0x7C,
+	0x57, 0xC5, 0x7A, 0x55, 0x87, 0x1B, 0xD4, 0x03,
+	0x0A, 0x64, 0xC9, 0xE0, 0xF4, 0xC7, 0x6F, 0x57,
+	0x52, 0xC6, 0x73, 0xBA, 0x84, 0x0B, 0x5B, 0x89,
+	0x21, 0xD2, 0x9B, 0x88, 0x68, 0xF5, 0xA9, 0x7F,
+	0x3F, 0x49, 0xEB, 0xF4, 0xD4, 0x52, 0xD2, 0x64,
+	0x80, 0xB2, 0x53, 0xDA, 0x19, 0xF6, 0x10, 0x24,
+	0x23, 0x26, 0x7A, 0x7C, 0x07, 0x57, 0x4B, 0x0E,
+	0x58, 0x49, 0x61, 0xD1, 0xDC, 0x9A, 0x32, 0x6B,
+	0x0F, 0x43, 0x9E, 0x4D, 0xB4, 0x07, 0x4E, 0xB3,
+	0x51, 0x74, 0xDE, 0x29, 0xBC, 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 0x33, 0xB0, 0x3D, 0xF6, 0xE2, 0x7E,
+	0x3E, 0xA2, 0x9E, 0xCA, 0x48, 0x0B, 0x4A, 0x29,
+	0x81, 0xD4, 0x4E, 0xD5, 0x69, 0xFB, 0xCD, 0x37,
+	0x8A, 0xC1, 0x5B, 0x50, 0xFF, 0xB5, 0x7D, 0x43,
+	0x0F, 0xAE, 0xA6, 0xC2, 0xE5, 0x8F, 0x45, 0xB2,
+	0x85, 0x99, 0x02, 0xA2, 0x9B, 0xBE, 0x90, 0x43,
+	0x4F, 0x2F, 0x50, 0xE2, 0x77, 0x62, 0xD9, 0xCC,
+	0x5D, 0x93, 0x6A, 0x97, 0xFB, 0x1D, 0x01, 0x17,
+	0x90, 0x61, 0x41, 0xD5, 0x5C, 0x43, 0x60, 0xBC,
+	0x21, 0x04, 0x5B, 0xB9, 0xFF, 0x75, 0xF8, 0x1F,
+	0x5C, 0x85, 0x91, 0x08, 0x02, 0xA2, 0xFD, 0x88, };
+
 /** AES-192-CBC test vector */
 static const struct blockcipher_test_data aes_test_data_10 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1761,6 +2042,51

@@ static const struct blockcipher_test_data aes_test_data_10 = {

app/test/test_cryptodev_aes_test_vectors.h +45 -0
 	}
 };
 
+/** AES-192-CBC SHA1 test vector (SSL/TLS order) */ static const struct
+blockcipher_test_data aes_test_data_10_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A,
+			0xD4, 0xC3, 0xA3, 0xAA, 0x33, 0x62, 0x61, 0xE0
+		},
+		.len = 24
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes192cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 static const uint8_t ciphertext512_aes256cbc[] = {
 	0xF3, 0xDD, 0xF0, 0x0B, 0xFF, 0xA2, 0x6A, 0x04,
 	0xBE, 0xDA, 0x52, 0xA6, 0xFE, 0x6B, 0xA6, 0xA7, @@ -1828,6 +2154,77

@@ static const uint8_t ciphertext512_aes256cbc[] = {

app/test/test_cryptodev_aes_test_vectors.h +70 -0
 	0xB7, 0x1C, 0x6D, 0xF2, 0xAE, 0x79, 0xA4, 0x7C  };
 
+static const uint8_t ciphertext512_aes256cbc_ssl[] = {
+	0xF3, 0xDD, 0xF0, 0x0B, 0xFF, 0xA2, 0x6A, 0x04,
+	0xBE, 0xDA, 0x52, 0xA6, 0xFE, 0x6B, 0xA6, 0xA7,
+	0x48, 0x1D, 0x7D, 0x98, 0x65, 0xDB, 0xEF, 0x06,
+	0x26, 0xB5, 0x8E, 0xEB, 0x05, 0x0E, 0x77, 0x98,
+	0x17, 0x8E, 0xD0, 0xD4, 0x7B, 0x92, 0x8F, 0x5C,
+	0xD0, 0x74, 0x5C, 0xA8, 0x4B, 0x54, 0xB6, 0x2F,
+	0x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48, 0xBA, 0xCE,
+	0xA9, 0xCE, 0xA6, 0x1D, 0xBF, 0x3E, 0x3C, 0x66,
+	0x40, 0x71, 0x79, 0xAD, 0x5B, 0x26, 0xAD, 0xBE,
+	0x58, 0x13, 0x64, 0x60, 0x7C, 0x05, 0xFC, 0xE3,
+	0x51, 0x7A, 0xF2, 0xCC, 0x54, 0x16, 0x2C, 0xA4,
+	0xCE, 0x5F, 0x59, 0x12, 0x77, 0xEB, 0xD9, 0x23,
+	0xE3, 0x86, 0xFB, 0xD7, 0x48, 0x76, 0x9D, 0xE3,
+	0x89, 0x87, 0x39, 0xFA, 0x7B, 0x21, 0x0B, 0x76,
+	0xB2, 0xED, 0x1C, 0x27, 0x4B, 0xD5, 0x27, 0x05,
+	0x8C, 0x7D, 0x58, 0x6C, 0xCA, 0xA5, 0x54, 0x9A,
+	0x0F, 0xCB, 0xE9, 0x88, 0x31, 0xAD, 0x49, 0xEE,
+	0x38, 0xFB, 0xC9, 0xFB, 0xB4, 0x7A, 0x00, 0x58,
+	0x20, 0x32, 0xD3, 0x53, 0x5A, 0xDD, 0x74, 0x95,
+	0x60, 0x59, 0x09, 0xAE, 0x7E, 0xEC, 0x74, 0xA3,
+	0xB7, 0x1C, 0x6D, 0xF2, 0xAE, 0x79, 0xA4, 0x7C,
+	0x50, 0xB1, 0x8D, 0x56, 0x22, 0x75, 0xD6, 0x8F,
+	0x93, 0xB5, 0xED, 0xE8, 0x3D, 0x20, 0x4F, 0x9F,
+	0x80, 0x2F, 0x56, 0x95, 0xA0, 0x80, 0xC6, 0xC2,
+	0xA8, 0x27, 0xFB, 0x48, 0x96, 0x58, 0xA1, 0x93, };
+
 /** AES-256-CBC test vector */
 static const struct blockcipher_test_data aes_test_data_11 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1857,6 +2254,52

@@ static const struct blockcipher_test_data aes_test_data_11 = {

app/test/test_cryptodev_aes_test_vectors.h +46 -0
 	}
 };
 
+/** AES-256-CBC SHA1 test vector (SSL/TLS order) */ static const struct
+blockcipher_test_data aes_test_data_11_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A,
+			0xD4, 0xC3, 0xA3, 0xAA, 0x33, 0x62, 0x61, 0xE0,
+			0x37, 0x07, 0xB8, 0x23, 0xA2, 0xA3, 0xB5, 0x8D
+		},
+		.len = 32
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes256cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 /** AES-128-CBC SHA256 HMAC test vector (160 bytes) */  static const struct

blockcipher_test_data aes_test_data_12 = {
.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1949,6 +2392,50
@@ static const struct blockcipher_test_data aes_test_data_13 = {

app/test/test_cryptodev_aes_test_vectors.h +44 -0
 	}
 };
 
+/** AES-128-CBC SHA1 test vector (SSL/TLS order) */ static const struct
+blockcipher_test_data aes_test_data_13_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A
+		},
+		.len = 16
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_short_ssl,
+		.len = 50
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes128cbc_short_ssl,
+		.len = 50
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA,
+			0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA,
+			0xAA, 0xAA, 0xAA, 0xAA
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x12, 0x5D, 0x73, 0x42, 0xB9, 0xAC, 0x11, 0xCD,
+			0x91, 0xA3, 0x9A, 0xF4, 0x8A, 0xA1, 0x7B, 0x4F,
+			0x63, 0xF1, 0x75, 0xD3
+		},
+		.len = 20,
+	}
+};
+
 /** XTS-AES-128 test vector (2 keys * 128 bit) */  static const uint8_t

plaintext_aes128xts_16bytes[] = {
0xEB, 0xAB, 0xCE, 0x95, 0xB1, 0x4D, 0x3C, 0x8D, @@ -2886,6 +3373,95
@@ static const struct blockcipher_test_case aes_cipheronly_test_cases[] = {

app/test/test_cryptodev_aes_test_vectors.h +89 -0
 		.test_data = &aes_test_data_21,
 		.op_mask = BLOCKCIPHER_TEST_OP_DECRYPT,
 	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest"
+			"(SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"(short buffers) (SSL/TLS order)",
+		.test_data = &aes_test_data_13_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-192-CBC HMAC-SHA1 Encryption Digest "
+			"Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_10_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-256-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_11_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG |
+			BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify (short buffers) (SSL/TLS order)",
+		.test_data = &aes_test_data_13_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-256-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_11_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-192-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_10_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS |
+				BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	}
 };
 
 static const struct blockcipher_test_case aes_docsis_test_cases[] = { diff --git

a/app/test/test_cryptodev_blockcipher.c
b/app/test/test_cryptodev_blockcipher.c
index 135e57b9fa..9d112d033c 100644

app/test/test_cryptodev_blockcipher.c +1 -0
@@ -94,6 +94,7 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 	uint8_t dst_pattern = 0xb6;
 	uint8_t tmp_src_buf[MBUF_SIZE];
 	uint8_t tmp_dst_buf[MBUF_SIZE];
+	uint32_t pad_len;
 
 	int nb_segs = 1;
app/test/test_cryptodev_blockcipher.c +0 -0
 	uint32_t nb_iterates = 0;

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct · line 192

Quoted 7 lines
app/test/test_cryptodev_blockcipher.c +3 -0
@@ -185,6 +186,22 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 	if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH)
 		buf_len += digest_len;
 
+	/* only aes-cbc cipher is supported for
+	 * auth followed by encryption case
+	 */

[Arek] - I though that without extension all non-AEAD algorithms (excluding AES-CCM) are MAC-then-encrypt in TLS.

Quoted 230 lines
app/test/test_cryptodev_blockcipher.c +13 -0
+	if ((t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER) &&
+		(t->test_data->crypto_algo != RTE_CRYPTO_CIPHER_AES_CBC))
 {
+		snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN,
+			"line %u FAILED: %s",
+			__LINE__, "Unsupported cipher algorithm");
+		status = TEST_FAILED;
+		goto error_exit;
+	}
+
+	pad_len = RTE_ALIGN(buf_len, 16) - buf_len;
+	if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+		buf_len += pad_len;
+
 	/* for contiguous mbuf, nb_segs is 1 */
app/test/test_cryptodev_blockcipher.c +0 -0
 	ibuf = create_segmented_mbuf(mbuf_pool,
 			tdata->ciphertext.len, nb_segs, src_pattern); @@ -

209,9 +226,31 @@ test_blockcipher_one_case(const struct blockcipher_test_case *t,

app/test/test_cryptodev_blockcipher.c +10 -1
 	buf_p = rte_pktmbuf_append(ibuf, digest_len);
 	if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_VERIFY)
-		rte_memcpy(buf_p, tdata->digest.data, digest_len);
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+			rte_memcpy(buf_p,
+				tdata->ciphertext.data + tdata->ciphertext.len,
+				 digest_len);
+		else
+			rte_memcpy(buf_p, tdata->digest.data, digest_len);
 	else
 		memset(buf_p, 0, digest_len);
+	if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER) {
+		buf_p = rte_pktmbuf_append(ibuf, pad_len);
+		if (!buf_p) {
+			snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN, "line

%u "

app/test/test_cryptodev_blockcipher.c +14 -1
+				"FAILED: %s", __LINE__,
+				"No room to append mbuf");
+			status = TEST_FAILED;
+			goto error_exit;
+		}
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_VERIFY) {
+			const uint8_t *temp_p = tdata->ciphertext.data +
+					tdata->ciphertext.len +
+					digest_len;
+			rte_memcpy(buf_p, temp_p, pad_len);
+		} else
+			memset(buf_p, 0xa5, pad_len);
+	}
 
 	if (t->feature_mask & BLOCKCIPHER_TEST_FEATURE_OOP) {
 		obuf = rte_pktmbuf_alloc(mbuf_pool);
@@ -224,7 +263,7 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		}
 		memset(obuf->buf_addr, dst_pattern, obuf->buf_len);
 
-		buf_p = rte_pktmbuf_append(obuf, buf_len);
+		buf_p = rte_pktmbuf_append(obuf, buf_len + pad_len);
 		if (!buf_p) {
 			snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN, "line

%u "

app/test/test_cryptodev_blockcipher.c +20 -0
 				"FAILED: %s", __LINE__,
@@ -359,6 +398,26 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 			cipher_xform->next = NULL;
 			init_xform = auth_xform;
 		}
+	} else if (t->op_mask == BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC) {
+		if (t->feature_mask &
 BLOCKCIPHER_TEST_FEATURE_SESSIONLESS) {
+			auth_xform = op->sym->xform;
+			cipher_xform = auth_xform->next;
+			cipher_xform->next = NULL;
+		} else {
+			auth_xform->next = cipher_xform;
+			cipher_xform->next = NULL;
+			init_xform = auth_xform;
+		}
+	} else if (t->op_mask == BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY) {
+		if (t->feature_mask &
 BLOCKCIPHER_TEST_FEATURE_SESSIONLESS) {
+			cipher_xform = op->sym->xform;
+			auth_xform = cipher_xform->next;
+			auth_xform->next = NULL;
+		} else {
+			cipher_xform->next = auth_xform;
+			auth_xform->next = NULL;
+			init_xform = cipher_xform;
+		}
app/test/test_cryptodev_blockcipher.c +0 -0
 	} else if ((t->op_mask == BLOCKCIPHER_TEST_OP_ENCRYPT) ||
 			(t->op_mask == BLOCKCIPHER_TEST_OP_DECRYPT)) {
 		if (t->feature_mask &

BLOCKCIPHER_TEST_FEATURE_SESSIONLESS)

app/test/test_cryptodev_blockcipher.c +4 -0
@@ -403,6 +462,10 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		sym_op->cipher.data.offset = tdata->cipher_offset;
 		sym_op->cipher.data.length = tdata->ciphertext.len -
 				tdata->cipher_offset;
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER) {
+			sym_op->cipher.data.length += tdata->digest.len;
+			sym_op->cipher.data.length += pad_len;
+		}
 		rte_memcpy(rte_crypto_op_ctod_offset(op, uint8_t *,
 IV_OFFSET),
app/test/test_cryptodev_blockcipher.c +2 -0
 				tdata->iv.data,
 				tdata->iv.len);
@@ -540,6 +603,8 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 					tdata->cipher_offset;
 			compare_len = tdata->ciphertext.len -
 					tdata->cipher_offset;
+			if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+				compare_len += tdata->digest.len;
 		} else {
 			compare_ref = tdata->plaintext.data +
app/test/test_cryptodev_blockcipher.c +5 -5
 					tdata->cipher_offset;
@@ -558,18 +623,20 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		}
 	}
 
-	if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_GEN) {
-		uint8_t *auth_res = pktmbuf_mtod_offset(iobuf,
-					tdata->ciphertext.len);
+	/* Check digest data only in enc-then-auth_gen case */
+	if (!(t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER))
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_GEN) {
+			uint8_t *auth_res = pktmbuf_mtod_offset(iobuf,
+						tdata->ciphertext.len);
 
-		if (memcmp(auth_res, tdata->digest.data, digest_len)) {
-			snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN, "line

%u "

app/test/test_cryptodev_blockcipher.c +2 -4
-				"FAILED: %s", __LINE__, "Generated "
-				"digest data not as expected");
-			status = TEST_FAILED;
-			goto error_exit;
+			if (memcmp(auth_res, tdata->digest.data, digest_len)) {
+				snprintf(test_msg,

BLOCKCIPHER_TEST_MSG_LEN, "line %u "

app/test/test_cryptodev_blockcipher.c +9 -1
+					"FAILED: %s", __LINE__, "Generated "
+					"digest data not as expected");
+				status = TEST_FAILED;
+				goto error_exit;
+			}
 		}
-	}
 
 	/* The only parts that should have changed in the buffer are
 	 * plaintext/ciphertext and digest.
@@ -631,6 +698,10 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 			changed_len = sym_op->cipher.data.length;
 		}
 
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+			changed_len = sym_op->cipher.data.length +
+				digest_len + pad_len;
+
 		for (i = 0; i < mbuf->buf_len; i++) {
 			if (i == head_unchanged_len)
app/test/test_cryptodev_blockcipher.c +3 -0
 				i += changed_len;
@@ -687,6 +758,9 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_GEN)
 			changed_len += digest_len;
 
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+			changed_len = sym_op->cipher.data.length;
+
 		for (i = 0; i < mbuf->buf_len; i++) {
 
app/test/test_cryptodev_blockcipher.c +0 -0
 			/* Skip headroom used by PMD */
app/test/test_cryptodev_blockcipher.h +3 -0
index 8990716844..c72cfe5342 100644
@@ -13,6 +13,7 @@
 #define BLOCKCIPHER_TEST_OP_DECRYPT		0x02
 #define BLOCKCIPHER_TEST_OP_AUTH_GEN	0x04
 #define BLOCKCIPHER_TEST_OP_AUTH_VERIFY	0x08
+#define BLOCKCIPHER_TEST_OP_SSL_ORDER	0x10
 
 #define BLOCKCIPHER_TEST_FEATURE_OOP			0x01
 #define BLOCKCIPHER_TEST_FEATURE_SESSIONLESS	0x02
@@ -31,6 +32,14 @@
 #define BLOCKCIPHER_TEST_OP_AUTH_VERIFY_DEC
 	(BLOCKCIPHER_TEST_OP_DECRYPT | \
 
 	BLOCKCIPHER_TEST_OP_AUTH_VERIFY)
 
+#define BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC
 	(BLOCKCIPHER_TEST_OP_ENCRYPT | \
+					BLOCKCIPHER_TEST_OP_AUTH_GEN |

\

app/test/test_cryptodev_blockcipher.h +3 -0
+					BLOCKCIPHER_TEST_OP_SSL_ORDER)
+
+#define BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY
	(BLOCKCIPHER_TEST_OP_DECRYPT | \
app/test/test_cryptodev_blockcipher.h +1 -0
+					BLOCKCIPHER_TEST_OP_AUTH_VERIFY

| \

app/test/test_cryptodev_blockcipher.h +2 -0
+					BLOCKCIPHER_TEST_OP_SSL_ORDER)
+
 enum blockcipher_test_type {
 	BLKCIPHER_AES_CHAIN_TYPE,	/* use aes_chain_test_cases[] */
 	BLKCIPHER_AES_CIPHERONLY_TYPE,	/* use

aes_cipheronly_test_cases[] */

doc/guides/rel_notes/release_21_02.rst +0 -0
index d1d4b25665..eb2d4ab2d9 100644
@@ -61,6 +61,12 @@ New Features
     followed by encryption and decryption followed by auth verify in OCTEONT

TX
and OCTEON TX2 crypto PMDs.

doc/guides/rel_notes/release_21_02.rst +6 -1
+* **Updated unit test sample application.**
+
+  * Added SSL/TLS way of cipher-auth operations support i.e. auth generation
+    followed by encryption and decryption followed by auth verify in sample
+    unit test application.
+
 
 Removed Items
 -------------
--

2.27.0

#9 lore raw

Re: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Hi Arek,

Please see inline.

Thanks
Tejasree

Quoted 698 lines

-----Original Message-----
From: Kusztal, ArkadiuszX <[email protected]>
Sent: Thursday, January 21, 2021 2:56 PM
To: Tejasree Kondoj <[email protected]>; Akhil Goyal <[email protected]>; Nicolau, Radu <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [EXT] RE: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

External Email

----------------------------------------------------------------------
Hi Tejasree,

Quoted 11 lines

-----Original Message-----
From: dev <[email protected]> On Behalf Of Tejasree Kondoj
Sent: piątek, 18 grudnia 2020 15:10
To: Akhil Goyal <[email protected]>; Nicolau, Radu <[email protected]>
Cc: Tejasree Kondoj <[email protected]>; Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [dpdk-dev] [PATCH 2/2] test/crypto: support SSL/TLS way of cipher-auth operations

Quoted 7 lines

Adding support for SSL/TLS way of cipher-auth operations order
- auth generation followed by encryption
- decryption followed by auth verify

---
 app/test/test_cryptodev_aes_test_vectors.h | 576

+++++++++++++++++++++

Quoted 171 lines
 app/test/test_cryptodev_blockcipher.c      |  98 +++-
 app/test/test_cryptodev_blockcipher.h      |   9 +
 doc/guides/rel_notes/release_21_02.rst     |   6 +
 4 files changed, 677 insertions(+), 12 deletions(-)
app/test/test_cryptodev_aes_test_vectors.h +157 -0
index c192d75a7e..c239c1cb35 100644
@@ -1093,6 +1093,172 @@ static const uint8_t
 ciphertext512_aes128cbc_aad[] = {
 	0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75  };
 
+static const uint8_t plaintext_aes_common_ssl[] = {
+	0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+	0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+	0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+	0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+	0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+	0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+	0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+	0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+	0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+	0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+	0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+	0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+	0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+	0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+	0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+	0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+	0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
+	0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+	0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+	0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+	0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+	0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+	0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+	0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+	0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+	0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+	0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+	0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+	0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+	0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+	0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+	0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+	0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+	0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+	0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+	0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+	0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+	0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+	0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+	0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+	0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+	0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+	0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+	0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+	0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+	0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+	0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+	0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+	0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+	0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+	0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+	0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+	0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+	0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+	0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+	0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+	0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+	0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+	0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+	0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+	0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+	0x20, 0x77, 0x69, 0x6E, 0x6E, 0x65, 0x72, 0x73,
+	0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x6c, 0x6f,
+	0x73, 0x65, 0x72, 0x73, 0x2c, 0x20, 0x73, 0x75,
+	/* mac */
+	0xC4, 0xB7, 0x0E, 0x6B, 0xDE, 0xD1, 0xE7, 0x77,
+	0x7E, 0x2E, 0x8F, 0xFC, 0x48, 0x39, 0x46, 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rypted mac */
+	0x39, 0x34, 0x16, 0x84, 0xE7, 0x90, 0x02, 0xB1,
+	0x3E, 0x92, 0xCB, 0x58, 0x98, 0xBA, 0x7C, 0x98,
+	0x8B, 0x90, 0xFB, 0x5E, 0x9D, 0x74, 0xCC, 0x56,
+	0xE3, 0x55, 0xB1, 0xC8, 0xC8, 0x7C, 0xB2, 0xE7 };
+
+static const uint8_t plaintext_aes_common_short_ssl[] = {
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD,
+	0xDD, 0xDD
+};
+
+static const uint8_t ciphertext512_aes128cbc_short_ssl[] = {
+	0x6D, 0xB1, 0x23, 0x86, 0x58, 0x54, 0x83, 0xE7,
+	0x3B, 0x27, 0x85, 0xA7, 0x06, 0xBC, 0x4A, 0xFB,
+	0x16, 0xD8, 0x56, 0x7C, 0x39, 0xC6, 0xE7, 0x1A,
+	0x67, 0xA8, 0x48, 0x22, 0xD6, 0xFF, 0x96, 0xB3,

app/test/test_cryptodev_aes_test_vectors.h static const uint8_t · line 1262

Quoted 10 lines
app/test/test_cryptodev_aes_test_vectors.h +7 -0
+	0xA1, 0x52, 0x52, 0x83, 0xE6, 0x2E, 0x6A, 0xC9,
+	0x57, 0x8E, 0x34, 0x6F, 0xEE, 0x41, 0xF5, 0xBD,
+	0x6B, 0x89, 0x31, 0x64, 0x89, 0xAB, 0xDE, 0xA7,
+	0xBD, 0xFD, 0x46, 0x40, 0xE7, 0x13, 0x23, 0x84,
+	0xDD, 0xCB, 0x35, 0x87, 0x4E, 0x57, 0xB7, 0x97,
+	0x9E, 0xAB, 0xFB, 0xE7, 0x18, 0x82, 0x05, 0xDF };
+
 /* AES128-CTR-SHA1 test vector */
 static const struct blockcipher_test_data aes_test_data_1 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CTR, @@ -1409,6 +1575,50

@@

Quoted 49 lines

static const struct blockcipher_test_data aes_test_data_4 = {

app/test/test_cryptodev_aes_test_vectors.h +44 -0
 	}
 };
 
+/** AES-128-CBC SHA1 test vector (SSL/TLS order) */ static const
+struct blockcipher_test_data aes_test_data_4_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A
+		},
+		.len = 16
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes128cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 /** AES-128-CBC SHA256 test vector */  static const struct
Quoted 2 lines

blockcipher_test_data aes_test_data_5 = {
.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1733,6 +1943,77

@@

Quoted 66 lines

static const uint8_t ciphertext512_aes192cbc[] = {

app/test/test_cryptodev_aes_test_vectors.h +63 -0
 	0x4F, 0x2F, 0x50, 0xE2, 0x77, 0x62, 0xD9, 0xCC  };
 
+static const uint8_t ciphertext512_aes192cbc_ssl[] = {
+	0x45, 0xee, 0x9a, 0xEA, 0x3C, 0x03, 0xFC, 0x4C,
+	0x84, 0x36, 0xB0, 0xDA, 0xB0, 0xDC, 0xF3, 0x5B,
+	0x75, 0xA7, 0xBE, 0x0E, 0xC0, 0x8D, 0x6C, 0xF8,
+	0xC1, 0x0F, 0xD0, 0x35, 0x1D, 0x82, 0xAE, 0x7C,
+	0x57, 0xC5, 0x7A, 0x55, 0x87, 0x1B, 0xD4, 0x03,
+	0x0A, 0x64, 0xC9, 0xE0, 0xF4, 0xC7, 0x6F, 0x57,
+	0x52, 0xC6, 0x73, 0xBA, 0x84, 0x0B, 0x5B, 0x89,
+	0x21, 0xD2, 0x9B, 0x88, 0x68, 0xF5, 0xA9, 0x7F,
+	0x3F, 0x49, 0xEB, 0xF4, 0xD4, 0x52, 0xD2, 0x64,
+	0x80, 0xB2, 0x53, 0xDA, 0x19, 0xF6, 0x10, 0x24,
+	0x23, 0x26, 0x7A, 0x7C, 0x07, 0x57, 0x4B, 0x0E,
+	0x58, 0x49, 0x61, 0xD1, 0xDC, 0x9A, 0x32, 0x6B,
+	0x0F, 0x43, 0x9E, 0x4D, 0xB4, 0x07, 0x4E, 0xB3,
+	0x51, 0x74, 0xDE, 0x29, 0xBC, 0x98, 0xF9, 0xDF,
+	0x78, 0x9A, 0x18, 0x9C, 0xD6, 0x7A, 0x55, 0x7C,
+	0xE6, 0x1D, 0x5C, 0x1A, 0x99, 0xD2, 0xC3, 0x7B,
+	0x9F, 0x96, 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0x37,
+	0x8A, 0xC1, 0x5B, 0x50, 0xFF, 0xB5, 0x7D, 0x43,
+	0x0F, 0xAE, 0xA6, 0xC2, 0xE5, 0x8F, 0x45, 0xB2,

app/test/test_cryptodev_aes_test_vectors.h static const uint8_t ciphertext512_aes192cbc[] = {

Quoted 10 lines
app/test/test_cryptodev_aes_test_vectors.h +7 -0
+	0x85, 0x99, 0x02, 0xA2, 0x9B, 0xBE, 0x90, 0x43,
+	0x4F, 0x2F, 0x50, 0xE2, 0x77, 0x62, 0xD9, 0xCC,
+	0x5D, 0x93, 0x6A, 0x97, 0xFB, 0x1D, 0x01, 0x17,
+	0x90, 0x61, 0x41, 0xD5, 0x5C, 0x43, 0x60, 0xBC,
+	0x21, 0x04, 0x5B, 0xB9, 0xFF, 0x75, 0xF8, 0x1F,
+	0x5C, 0x85, 0x91, 0x08, 0x02, 0xA2, 0xFD, 0x88, };
+
 /** AES-192-CBC test vector */
 static const struct blockcipher_test_data aes_test_data_10 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1761,6 +2042,51

@@

Quoted 42 lines

static const struct blockcipher_test_data aes_test_data_10 = {

app/test/test_cryptodev_aes_test_vectors.h +38 -0
 	}
 };
 
+/** AES-192-CBC SHA1 test vector (SSL/TLS order) */ static const
+struct blockcipher_test_data aes_test_data_10_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A,
+			0xD4, 0xC3, 0xA3, 0xAA, 0x33, 0x62, 0x61, 0xE0
+		},
+		.len = 24
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes192cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,

app/test/test_cryptodev_aes_test_vectors.h static const struct blockcipher_test_data aes_test_data_10 = {

Quoted 10 lines
app/test/test_cryptodev_aes_test_vectors.h +7 -0
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 static const uint8_t ciphertext512_aes256cbc[] = {
 	0xF3, 0xDD, 0xF0, 0x0B, 0xFF, 0xA2, 0x6A, 0x04,
 	0xBE, 0xDA, 0x52, 0xA6, 0xFE, 0x6B, 0xA6, 0xA7, @@ -1828,6

+2154,77

Quoted 66 lines

@@ static const uint8_t ciphertext512_aes256cbc[] = {

app/test/test_cryptodev_aes_test_vectors.h +63 -0
 	0xB7, 0x1C, 0x6D, 0xF2, 0xAE, 0x79, 0xA4, 0x7C  };
 
+static const uint8_t ciphertext512_aes256cbc_ssl[] = {
+	0xF3, 0xDD, 0xF0, 0x0B, 0xFF, 0xA2, 0x6A, 0x04,
+	0xBE, 0xDA, 0x52, 0xA6, 0xFE, 0x6B, 0xA6, 0xA7,
+	0x48, 0x1D, 0x7D, 0x98, 0x65, 0xDB, 0xEF, 0x06,
+	0x26, 0xB5, 0x8E, 0xEB, 0x05, 0x0E, 0x77, 0x98,
+	0x17, 0x8E, 0xD0, 0xD4, 0x7B, 0x92, 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CC, 0x0A, 0x69, 0x54, 0x25, 0x5E,
+	0x8B, 0xAC, 0x56, 0xD9, 0xFE, 0x48, 0xBA, 0xCE,
+	0xA9, 0xCE, 0xA6, 0x1D, 0xBF, 0x3E, 0x3C, 0x66,
+	0x40, 0x71, 0x79, 0xAD, 0x5B, 0x26, 0xAD, 0xBE,
+	0x58, 0x13, 0x64, 0x60, 0x7C, 0x05, 0xFC, 0xE3,
+	0x51, 0x7A, 0xF2, 0xCC, 0x54, 0x16, 0x2C, 0xA4,
+	0xCE, 0x5F, 0x59, 0x12, 0x77, 0xEB, 0xD9, 0x23,
+	0xE3, 0x86, 0xFB, 0xD7, 0x48, 0x76, 0x9D, 0xE3,
+	0x89, 0x87, 0x39, 0xFA, 0x7B, 0x21, 0x0B, 0x76,
+	0xB2, 0xED, 0x1C, 0x27, 0x4B, 0xD5, 0x27, 0x05,
+	0x8C, 0x7D, 0x58, 0x6C, 0xCA, 0xA5, 0x54, 0x9A,
+	0x0F, 0xCB, 0xE9, 0x88, 0x31, 0xAD, 0x49, 0xEE,
+	0x38, 0xFB, 0xC9, 0xFB, 0xB4, 0x7A, 0x00, 0x58,
+	0x20, 0x32, 0xD3, 0x53, 0x5A, 0xDD, 0x74, 0x95,

app/test/test_cryptodev_aes_test_vectors.h static const uint8_t ciphertext512_aes256cbc[] = {

Quoted 10 lines
app/test/test_cryptodev_aes_test_vectors.h +7 -0
+	0x60, 0x59, 0x09, 0xAE, 0x7E, 0xEC, 0x74, 0xA3,
+	0xB7, 0x1C, 0x6D, 0xF2, 0xAE, 0x79, 0xA4, 0x7C,
+	0x50, 0xB1, 0x8D, 0x56, 0x22, 0x75, 0xD6, 0x8F,
+	0x93, 0xB5, 0xED, 0xE8, 0x3D, 0x20, 0x4F, 0x9F,
+	0x80, 0x2F, 0x56, 0x95, 0xA0, 0x80, 0xC6, 0xC2,
+	0xA8, 0x27, 0xFB, 0x48, 0x96, 0x58, 0xA1, 0x93, };
+
 /** AES-256-CBC test vector */
 static const struct blockcipher_test_data aes_test_data_11 = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1857,6 +2254,52

@@

Quoted 51 lines

static const struct blockcipher_test_data aes_test_data_11 = {

app/test/test_cryptodev_aes_test_vectors.h +46 -0
 	}
 };
 
+/** AES-256-CBC SHA1 test vector (SSL/TLS order) */ static const
+struct blockcipher_test_data aes_test_data_11_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A,
+			0xD4, 0xC3, 0xA3, 0xAA, 0x33, 0x62, 0x61, 0xE0,
+			0x37, 0x07, 0xB8, 0x23, 0xA2, 0xA3, 0xB5, 0x8D
+		},
+		.len = 32
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_ssl,
+		.len = 512
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes256cbc_ssl,
+		.len = 512
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xF8, 0x2A, 0xC7, 0x54, 0xDB, 0x96, 0x18, 0xAA,
+			0xC3, 0xA1, 0x53, 0xF6, 0x1F, 0x17, 0x60, 0xBD,
+			0xDE, 0xF4, 0xDE, 0xAD
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x9A, 0x4F, 0x88, 0x1B, 0xB6, 0x8F, 0xD8, 0x60,
+			0x42, 0x1A, 0x7D, 0x3D, 0xF5, 0x82, 0x80, 0xF1,
+			0x18, 0x8C, 0x1D, 0x32
+		},
+		.len = 20,
+	}
+};
+
 /** AES-128-CBC SHA256 HMAC test vector (160 bytes) */  static const
Quoted 2 lines

struct blockcipher_test_data aes_test_data_12 = {
.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC, @@ -1949,6 +2392,50

@@

Quoted 49 lines

static const struct blockcipher_test_data aes_test_data_13 = {

app/test/test_cryptodev_aes_test_vectors.h +44 -0
 	}
 };
 
+/** AES-128-CBC SHA1 test vector (SSL/TLS order) */ static const
+struct blockcipher_test_data aes_test_data_13_ssl = {
+	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
+	.cipher_key = {
+		.data = {
+			0xE4, 0x23, 0x33, 0x8A, 0x35, 0x64, 0x61, 0xE2,
+			0x49, 0x03, 0xDD, 0xC6, 0xB8, 0xCA, 0x55, 0x7A
+		},
+		.len = 16
+	},
+	.iv = {
+		.data = {
+			0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+			0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
+		},
+		.len = 16
+	},
+	.plaintext = {
+		.data = plaintext_aes_common_short_ssl,
+		.len = 50
+	},
+	.ciphertext = {
+		.data = ciphertext512_aes128cbc_short_ssl,
+		.len = 50
+	},
+	.auth_algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
+	.auth_key = {
+		.data = {
+			0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA,
+			0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA,
+			0xAA, 0xAA, 0xAA, 0xAA
+		},
+		.len = 20
+	},
+	.digest = {
+		.data = {
+			0x12, 0x5D, 0x73, 0x42, 0xB9, 0xAC, 0x11, 0xCD,
+			0x91, 0xA3, 0x9A, 0xF4, 0x8A, 0xA1, 0x7B, 0x4F,
+			0x63, 0xF1, 0x75, 0xD3
+		},
+		.len = 20,
+	}
+};
+
 /** XTS-AES-128 test vector (2 keys * 128 bit) */  static const
Quoted 2 lines

uint8_t plaintext_aes128xts_16bytes[] = {
0xEB, 0xAB, 0xCE, 0x95, 0xB1, 0x4D, 0x3C, 0x8D, @@ -2886,6

+3373,95

Quoted 1 line

@@ static const struct blockcipher_test_case aes_cipheronly_test_cases[] =

{

Quoted 73 lines
app/test/test_cryptodev_aes_test_vectors.h +70 -0
 		.test_data = &aes_test_data_21,
 		.op_mask = BLOCKCIPHER_TEST_OP_DECRYPT,
 	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest"
+			"(SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"(short buffers) (SSL/TLS order)",
+		.test_data = &aes_test_data_13_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-192-CBC HMAC-SHA1 Encryption Digest "
+			"Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_10_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-256-CBC HMAC-SHA1 Encryption Digest "
+			"Scatter Gather Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_11_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG |
+			BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify (short buffers) (SSL/TLS order)",
+		.test_data = &aes_test_data_13_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-256-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Sessionless (SSL/TLS order)",

app/test/test_cryptodev_aes_test_vectors.h static const struct blockcipher_test_case aes_cipheronly_test_cases[] = {

Quoted 10 lines
app/test/test_cryptodev_aes_test_vectors.h +10 -0
+		.test_data = &aes_test_data_11_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	},
+	{
+		.test_descr = "AES-192-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Scatter Gather Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_10_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS

|

Quoted 31 lines
app/test/test_cryptodev_aes_test_vectors.h +9 -0
+				BLOCKCIPHER_TEST_FEATURE_SG,
+	},
+	{
+		.test_descr = "AES-128-CBC HMAC-SHA1 Decryption Digest "
+			"Verify Sessionless (SSL/TLS order)",
+		.test_data = &aes_test_data_4_ssl,
+		.op_mask = BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY,
+		.feature_mask = BLOCKCIPHER_TEST_FEATURE_SESSIONLESS,
+	}
 };
 
 static const struct blockcipher_test_case aes_docsis_test_cases[] = {
app/test/test_cryptodev_blockcipher.c +1 -0
index 135e57b9fa..9d112d033c 100644
@@ -94,6 +94,7 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 	uint8_t dst_pattern = 0xb6;
 	uint8_t tmp_src_buf[MBUF_SIZE];
 	uint8_t tmp_dst_buf[MBUF_SIZE];
+	uint32_t pad_len;
 
 	int nb_segs = 1;
app/test/test_cryptodev_blockcipher.c +0 -0
 	uint32_t nb_iterates = 0;
@@ -185,6 +186,22 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 	if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH)
 		buf_len += digest_len;
 
Quoted 5 lines

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct blockcipher_test_case *t, · line 191

Quoted 3 lines
app/test/test_cryptodev_blockcipher.c +3 -0
+	/* only aes-cbc cipher is supported for
+	 * auth followed by encryption case
+	 */

[Arek] - I though that without extension all non-AEAD algorithms (excluding AES-CCM) are MAC-then-encrypt in TLS.

[Tejasree] Yes but only AES-CBC cipher is supported in this patch. Other algorithms are not tested.

Quoted 241 lines

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct · line 194

Quoted 3 lines
app/test/test_cryptodev_blockcipher.c +2 -0
+	if ((t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER) &&
+		(t->test_data->crypto_algo !=

RTE_CRYPTO_CIPHER_AES_CBC))

Quoted 25 lines
app/test/test_cryptodev_blockcipher.c +11 -0
 {
+		snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN,
+			"line %u FAILED: %s",
+			__LINE__, "Unsupported cipher algorithm");
+		status = TEST_FAILED;
+		goto error_exit;
+	}
+
+	pad_len = RTE_ALIGN(buf_len, 16) - buf_len;
+	if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+		buf_len += pad_len;
+
 	/* for contiguous mbuf, nb_segs is 1 */
app/test/test_cryptodev_blockcipher.c +0 -0
 	ibuf = create_segmented_mbuf(mbuf_pool,
 			tdata->ciphertext.len, nb_segs, src_pattern); @@ -

209,9 +226,31 @@ test_blockcipher_one_case(const struct blockcipher_test_case *t,

app/test/test_cryptodev_blockcipher.c +3 -1
 	buf_p = rte_pktmbuf_append(ibuf, digest_len);
 	if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_VERIFY)
-		rte_memcpy(buf_p, tdata->digest.data, digest_len);
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+			rte_memcpy(buf_p,
+				tdata->ciphertext.data + tdata-

ciphertext.len,

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct blockcipher_test_case *t,

Quoted 9 lines
app/test/test_cryptodev_blockcipher.c +7 -0
+				 digest_len);
+		else
+			rte_memcpy(buf_p, tdata->digest.data, digest_len);
 	else
 		memset(buf_p, 0, digest_len);
+	if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER) {
+		buf_p = rte_pktmbuf_append(ibuf, pad_len);
+		if (!buf_p) {
+			snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN,

"line

Quoted 7 lines

%u "

app/test/test_cryptodev_blockcipher.c +6 -0
+				"FAILED: %s", __LINE__,
+				"No room to append mbuf");
+			status = TEST_FAILED;
+			goto error_exit;
+		}
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_VERIFY) {

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct blockcipher_test_case *t,

Quoted 10 lines
app/test/test_cryptodev_blockcipher.c +7 -0
+			const uint8_t *temp_p = tdata->ciphertext.data +
+					tdata->ciphertext.len +
+					digest_len;
+			rte_memcpy(buf_p, temp_p, pad_len);
+		} else
+			memset(buf_p, 0xa5, pad_len);
+	}
 
 	if (t->feature_mask & BLOCKCIPHER_TEST_FEATURE_OOP) {
 		obuf = rte_pktmbuf_alloc(mbuf_pool); @@ -224,7 +263,7

@@

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct blockcipher_test_case *t,

Quoted 8 lines

test_blockcipher_one_case(const struct blockcipher_test_case *t,

app/test/test_cryptodev_blockcipher.c +1 -1
 		}
 		memset(obuf->buf_addr, dst_pattern, obuf->buf_len);
 
-		buf_p = rte_pktmbuf_append(obuf, buf_len);
+		buf_p = rte_pktmbuf_append(obuf, buf_len + pad_len);
 		if (!buf_p) {
 			snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN,

"line %u "

Quoted 8 lines
app/test/test_cryptodev_blockcipher.c +2 -0
 				"FAILED: %s", __LINE__,
@@ -359,6 +398,26 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 			cipher_xform->next = NULL;
 			init_xform = auth_xform;
 		}
+	} else if (t->op_mask == BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC) {
+		if (t->feature_mask &

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct · line 413

Quoted 10 lines
app/test/test_cryptodev_blockcipher.c +9 -0
 BLOCKCIPHER_TEST_FEATURE_SESSIONLESS) {
+			auth_xform = op->sym->xform;
+			cipher_xform = auth_xform->next;
+			cipher_xform->next = NULL;
+		} else {
+			auth_xform->next = cipher_xform;
+			cipher_xform->next = NULL;
+			init_xform = auth_xform;
+		}
+	} else if (t->op_mask == BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY)

{

Quoted 15 lines
app/test/test_cryptodev_blockcipher.c +9 -0
+		if (t->feature_mask &
 BLOCKCIPHER_TEST_FEATURE_SESSIONLESS) {
+			cipher_xform = op->sym->xform;
+			auth_xform = cipher_xform->next;
+			auth_xform->next = NULL;
+		} else {
+			cipher_xform->next = auth_xform;
+			auth_xform->next = NULL;
+			init_xform = cipher_xform;
+		}
app/test/test_cryptodev_blockcipher.c +0 -0
 	} else if ((t->op_mask == BLOCKCIPHER_TEST_OP_ENCRYPT) ||
 			(t->op_mask == BLOCKCIPHER_TEST_OP_DECRYPT)) {
 		if (t->feature_mask &

BLOCKCIPHER_TEST_FEATURE_SESSIONLESS)

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct · line 470

Quoted 9 lines
app/test/test_cryptodev_blockcipher.c +4 -0
@@ -403,6 +462,10 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		sym_op->cipher.data.offset = tdata->cipher_offset;
 		sym_op->cipher.data.length = tdata->ciphertext.len -
 				tdata->cipher_offset;
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER) {
+			sym_op->cipher.data.length += tdata->digest.len;
+			sym_op->cipher.data.length += pad_len;
+		}
 		rte_memcpy(rte_crypto_op_ctod_offset(op, uint8_t *,

IV_OFFSET),

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct · line 607

Quoted 8 lines
app/test/test_cryptodev_blockcipher.c +0 -0
 				tdata->iv.data,
app/test/test_cryptodev_blockcipher.c +1 -0
 				tdata->iv.len);
@@ -540,6 +603,8 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 					tdata->cipher_offset;
 			compare_len = tdata->ciphertext.len -
 					tdata->cipher_offset;
+			if (t->op_mask &

BLOCKCIPHER_TEST_OP_SSL_ORDER)

Quoted 10 lines
app/test/test_cryptodev_blockcipher.c +1 -0
+				compare_len += tdata->digest.len;
 		} else {
 			compare_ref = tdata->plaintext.data +
app/test/test_cryptodev_blockcipher.c +0 -1
 					tdata->cipher_offset;
@@ -558,18 +623,20 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		}
 	}
 
-	if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_GEN) {

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct · line 567

Quoted 10 lines
app/test/test_cryptodev_blockcipher.c +5 -4
-		uint8_t *auth_res = pktmbuf_mtod_offset(iobuf,
-					tdata->ciphertext.len);
+	/* Check digest data only in enc-then-auth_gen case */
+	if (!(t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER))
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_GEN) {
+			uint8_t *auth_res = pktmbuf_mtod_offset(iobuf,
+						tdata->ciphertext.len);
 
-		if (memcmp(auth_res, tdata->digest.data, digest_len)) {
-			snprintf(test_msg, BLOCKCIPHER_TEST_MSG_LEN,

"line

app/test/test_cryptodev_blockcipher.c test_blockcipher_one_case(const struct blockcipher_test_case *t,

Quoted 6 lines

%u "

app/test/test_cryptodev_blockcipher.c +1 -4
-				"FAILED: %s", __LINE__, "Generated "
-				"digest data not as expected");
-			status = TEST_FAILED;
-			goto error_exit;
+			if (memcmp(auth_res, tdata->digest.data,

digest_len)) {

Quoted 62 lines
app/test/test_cryptodev_blockcipher.c +1 -0
+				snprintf(test_msg,

BLOCKCIPHER_TEST_MSG_LEN, "line %u "

app/test/test_cryptodev_blockcipher.c +9 -1
+					"FAILED: %s", __LINE__, "Generated "
+					"digest data not as expected");
+				status = TEST_FAILED;
+				goto error_exit;
+			}
 		}
-	}
 
 	/* The only parts that should have changed in the buffer are
 	 * plaintext/ciphertext and digest.
@@ -631,6 +698,10 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 			changed_len = sym_op->cipher.data.length;
 		}
 
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+			changed_len = sym_op->cipher.data.length +
+				digest_len + pad_len;
+
 		for (i = 0; i < mbuf->buf_len; i++) {
 			if (i == head_unchanged_len)
app/test/test_cryptodev_blockcipher.c +3 -0
 				i += changed_len;
@@ -687,6 +758,9 @@ test_blockcipher_one_case(const struct
 blockcipher_test_case *t,
 		if (t->op_mask & BLOCKCIPHER_TEST_OP_AUTH_GEN)
 			changed_len += digest_len;
 
+		if (t->op_mask & BLOCKCIPHER_TEST_OP_SSL_ORDER)
+			changed_len = sym_op->cipher.data.length;
+
 		for (i = 0; i < mbuf->buf_len; i++) {
 
app/test/test_cryptodev_blockcipher.c +0 -0
 			/* Skip headroom used by PMD */
app/test/test_cryptodev_blockcipher.h +3 -0
index 8990716844..c72cfe5342 100644
@@ -13,6 +13,7 @@
 #define BLOCKCIPHER_TEST_OP_DECRYPT		0x02
 #define BLOCKCIPHER_TEST_OP_AUTH_GEN	0x04
 #define BLOCKCIPHER_TEST_OP_AUTH_VERIFY	0x08
+#define BLOCKCIPHER_TEST_OP_SSL_ORDER	0x10
 
 #define BLOCKCIPHER_TEST_FEATURE_OOP			0x01
 #define BLOCKCIPHER_TEST_FEATURE_SESSIONLESS	0x02
@@ -31,6 +32,14 @@
 #define BLOCKCIPHER_TEST_OP_AUTH_VERIFY_DEC
 	(BLOCKCIPHER_TEST_OP_DECRYPT | \
 
 	BLOCKCIPHER_TEST_OP_AUTH_VERIFY)
 
+#define BLOCKCIPHER_TEST_OP_AUTH_GEN_ENC
 	(BLOCKCIPHER_TEST_OP_ENCRYPT | \
+					BLOCKCIPHER_TEST_OP_AUTH_GEN |

\

app/test/test_cryptodev_blockcipher.h +3 -0
+					BLOCKCIPHER_TEST_OP_SSL_ORDER)
+
+#define BLOCKCIPHER_TEST_OP_DEC_AUTH_VERIFY
	(BLOCKCIPHER_TEST_OP_DECRYPT | \
Quoted 1 line

+

BLOCKCIPHER_TEST_OP_AUTH_VERIFY

Quoted 17 lines

| \

app/test/test_cryptodev_blockcipher.h +2 -0
+					BLOCKCIPHER_TEST_OP_SSL_ORDER)
+
 enum blockcipher_test_type {
 	BLKCIPHER_AES_CHAIN_TYPE,	/* use aes_chain_test_cases[] */
 	BLKCIPHER_AES_CIPHERONLY_TYPE,	/* use

aes_cipheronly_test_cases[] */

doc/guides/rel_notes/release_21_02.rst +0 -0
index d1d4b25665..eb2d4ab2d9 100644
@@ -61,6 +61,12 @@ New Features
     followed by encryption and decryption followed by auth verify in

OCTEONT TX
and OCTEON TX2 crypto PMDs.

doc/guides/rel_notes/release_21_02.rst New Features

Quoted 3 lines
doc/guides/rel_notes/release_21_02.rst +3 -0
+* **Updated unit test sample application.**
+
+  * Added SSL/TLS way of cipher-auth operations support i.e. auth

generation

Quoted 1 line

+ followed by encryption and decryption followed by auth verify in

sample

Quoted 7 lines
doc/guides/rel_notes/release_21_02.rst +2 -1
+    unit test application.
+
 
 Removed Items
 -------------
--

2.27.0

#12 lore raw
In reply to Tejasree Kondoj

Hi Tejasree,

Sorry I missed this mail earlier. I believe it is same as Digest encrypted case.

Quoted 49 lines

-----Original Message-----
From: Tejasree Kondoj <[email protected]>
Sent: Thursday, January 21, 2021 12:57 PM
To: Tejasree Kondoj <[email protected]>; Akhil Goyal <[email protected]>; Radu Nicolau <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]; Zhang, Roy Fan <[email protected]>; Trahe, Fiona <[email protected]>
Subject: RE: [PATCH 0/2] support SSL/TLS way of cipher-auth operations

Hi Akhil,

I'm planning to add device feature flag(RTE_CRYPTODEV_FF_SSL_ORDER) along with SSL test cases movement to chain array in v2. Would that be fine? Feature flag is needed to skip SSL test cases if device doesn't support them.

Thanks
Tejasree

Quoted 30 lines

-----Original Message-----
From: Tejasree Kondoj <[email protected]>
Sent: Friday, December 18, 2020 7:40 PM
To: Akhil Goyal <[email protected]>; Radu Nicolau <[email protected]>
Cc: Tejasree Kondoj <[email protected]>; Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [PATCH 0/2] support SSL/TLS way of cipher-auth operations

This series adds SSL/TLS way of cipher-auth operations support i.e. auth generation followed by encryption and decryption followed by auth verify in OCTEON TX, OCTEON TX2 PMDs and sample unit test application.

Tejasree Kondoj (2):
common/cpt: support SSL/TLS way of cipher-auth operations test/crypto: support SSL/TLS way of cipher-auth operations

 app/test/test_cryptodev_aes_test_vectors.h    | 576 ++++++++++++++++++
 app/test/test_cryptodev_blockcipher.c         |  98 ++-
 app/test/test_cryptodev_blockcipher.h         |   9 +
 doc/guides/rel_notes/release_21_02.rst        |  12 +
 drivers/common/cpt/cpt_mcode_defines.h        |   7 +-
 drivers/common/cpt/cpt_ucode.h                |  42 +-
 drivers/crypto/octeontx/otx_cryptodev_ops.c   |   8 +-
 drivers/crypto/octeontx2/otx2_cryptodev_ops.c |   8 +-
 8 files changed, 736 insertions(+), 24 deletions(-)

--
2.27.0

#13 lore raw

Hi Akhil,

Okay. Will use FF_DIGEST_ENCRYPTED flag instead of FF_SSL_ORDER.

Thanks
Tejasree

Quoted 69 lines

-----Original Message-----
From: Akhil Goyal <[email protected]>
Sent: Monday, January 25, 2021 10:27 PM
To: Tejasree Kondoj <[email protected]>; Radu Nicolau <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]; Zhang, Roy Fan <[email protected]>; Trahe, Fiona <[email protected]>
Subject: [EXT] RE: [PATCH 0/2] support SSL/TLS way of cipher-auth operations

External Email

----------------------------------------------------------------------
Hi Tejasree,

Sorry I missed this mail earlier. I believe it is same as Digest encrypted case.

Quoted 10 lines

-----Original Message-----
From: Tejasree Kondoj <[email protected]>
Sent: Thursday, January 21, 2021 12:57 PM
To: Tejasree Kondoj <[email protected]>; Akhil Goyal <[email protected]>; Radu Nicolau <[email protected]>
Cc: Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]; Zhang, Roy Fan <[email protected]>; Trahe, Fiona <[email protected]>
Subject: RE: [PATCH 0/2] support SSL/TLS way of cipher-auth operations

Quoted 4 lines

Hi Akhil,

I'm planning to add device feature flag(RTE_CRYPTODEV_FF_SSL_ORDER) along with SSL test cases movement to chain array in v2. Would that be

fine?

Quoted 18 lines

Feature flag is needed to skip SSL test cases if device doesn't support them.

Thanks
Tejasree

Quoted 13 lines

-----Original Message-----
From: Tejasree Kondoj <[email protected]>
Sent: Friday, December 18, 2020 7:40 PM
To: Akhil Goyal <[email protected]>; Radu Nicolau <[email protected]>
Cc: Tejasree Kondoj <[email protected]>; Anoob Joseph <[email protected]>; Ankur Dwivedi <[email protected]>; [email protected]
Subject: [PATCH 0/2] support SSL/TLS way of cipher-auth operations

This series adds SSL/TLS way of cipher-auth operations support i.e. auth generation followed by encryption and decryption followed by auth verify in OCTEON TX, OCTEON TX2 PMDs and sample unit test

application.

Quoted 6 lines
Quoted 6 lines

Tejasree Kondoj (2):
common/cpt: support SSL/TLS way of cipher-auth operations test/crypto: support SSL/TLS way of cipher-auth operations

 app/test/test_cryptodev_aes_test_vectors.h    | 576

++++++++++++++++++

Quoted 11 lines
Quoted 11 lines
 app/test/test_cryptodev_blockcipher.c         |  98 ++-
 app/test/test_cryptodev_blockcipher.h         |   9 +
 doc/guides/rel_notes/release_21_02.rst        |  12 +
 drivers/common/cpt/cpt_mcode_defines.h        |   7 +-
 drivers/common/cpt/cpt_ucode.h                |  42 +-
 drivers/crypto/octeontx/otx_cryptodev_ops.c   |   8 +-
 drivers/crypto/octeontx2/otx2_cryptodev_ops.c |   8 +-
 8 files changed, 736 insertions(+), 24 deletions(-)

--
2.27.0