From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7E795A0C46; Fri, 17 Sep 2021 15:15:41 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4D3E8406B4; Fri, 17 Sep 2021 15:15:41 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id 89B2340689 for ; Fri, 17 Sep 2021 15:15:39 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 18HCkwgE018561; Fri, 17 Sep 2021 06:15:38 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=V10NdpxqStdP0kh/lCmuVrc5W8mS5EGPxJSn9rPN/MQ=; b=kMK7Ovp73LIzzM5Mh9lJ8J9PsDv4NwHFTF/GoEbBkfXXH89z0BzJUJzKj9VWMozmN/tA 8djy7yqNfWKw+m4s7P1RQip0ietXAaqrslrYVGS61cUNOzOfBwikh7RHAEn1FZun9R0Q MByrUn1wuF/E0vg0AQ30dWR0Qha6ADNMY8DbCQC8PsBeCE78GB+D7XJaVaVMb174+X4b /yulCymFMxeaYjY+zn/3OUgCB8tr4mN8S1Q35oQnyl3mc/tMQFmZrh3LoKMN5s4SJAPW 9kELi+W5YCA/+hLQwXrOvqNYkqd0vG48iZ/YCvccAvQo2NQFe6dFVsTEyBnNLqa5tXoE MA== Received: from dc5-exch02.marvell.com ([199.233.59.182]) by mx0a-0016f401.pphosted.com with ESMTP id 3b4uasg2um-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Fri, 17 Sep 2021 06:15:38 -0700 Received: from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Fri, 17 Sep 2021 06:15:37 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Fri, 17 Sep 2021 06:15:37 -0700 Received: from HY-LT1002.marvell.com (HY-LT1002.marvell.com [10.28.176.218]) by maili.marvell.com (Postfix) with ESMTP id 7B8C13F704E; Fri, 17 Sep 2021 06:15:32 -0700 (PDT) From: Anoob Joseph To: Akhil Goyal , Declan Doherty , Fan Zhang , "Konstantin Ananyev" CC: Anoob Joseph , Jerin Jacob , Archana Muniganti , Tejasree Kondoj , Hemant Agrawal , "Radu Nicolau" , Ciara Power , Gagandeep Singh , Date: Fri, 17 Sep 2021 18:45:18 +0530 Message-ID: <1631884523-836-1-git-send-email-anoobj@marvell.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1630644420-1256-1-git-send-email-anoobj@marvell.com> References: <1630644420-1256-1-git-send-email-anoobj@marvell.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Proofpoint-GUID: _u4PNiMkNqjBHjK9yElmCfYKz7-esdu1 X-Proofpoint-ORIG-GUID: _u4PNiMkNqjBHjK9yElmCfYKz7-esdu1 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.391,FMLib:17.0.607.475 definitions=2021-09-17_05,2021-09-17_02,2020-04-07_01 Subject: [dpdk-dev] [PATCH v4 0/5] Add lookaside IPsec tests X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Add lookaside IPsec functional tests. Known vector tests and combined mode framework is added. Known vectors are outbound vectors based on https://datatracker.ietf.org/doc/html/draft-mcgrew-gcm-test-01 The vectors are updated to have sequence number as 1 & L4 checksum computed correctly. And they have following properties, 1. ESP 2. Tunnel mode 3. IPv4 4. IPv4 tunnel Known vector tests for inbound operation would generate test vectors by reversing outbound known vectors. The input_text would become encrypted packet and output_text would be the plain packet. Tests would then validate the operation by comparing against plain packet. Combined mode tests are used to test all IPsec features against all ciphers supported by the PMD. The framework is introduced to avoid testing with any specific algo, thereby making it mandatory to be supported. Also, testing with all supported combinations will help with increasing coverage as well. Four test cases use combined mode, 1. Display algo coverage and basic in + out tests 2. Negative test for ICV corruption 3. IV generation 4. UDP encapsulation IV generation test case compares IV generated for a batch of packets and returns failure if IV is repeated. Upcoming additions, 1. AES-CBC-SHA1-HMAC known vectors & combined mode 2. IPv6 3. Transport 4. Mixed mode (IPv4-in-IPv6 etc, all combinations) Tested with following PMDs 1. crypto_octeontx2 2. crypto_cn10k 3. crypto_cn9k Changes in v4: - Fixed lack of device stop in case capability check fails (comment from Ciara) - Rebased and updated release notes Changes in v3 - Added UDP encapsulation tests Changes in v2 - Dropped outbound known vector tests as lookaside protocol would require IV generated by PMD. The tests would be introduced with spec change to allow user to specify IV. - Added IV generation tests - Minor fixes in combined mode tests to handle multiple packets Anoob Joseph (2): test/crypto: add lookaside IPsec tests test/crypto: add combined mode tests Tejasree Kondoj (3): test/crypto: add lookaside IPsec ICV corrupt test case test/crypto: add IV gen tests test/crypto: add UDP encapsulation test cases app/test/meson.build | 1 + app/test/test.h | 6 + app/test/test_cryptodev.c | 351 ++++++++++++++++++ app/test/test_cryptodev_security_ipsec.c | 401 +++++++++++++++++++++ app/test/test_cryptodev_security_ipsec.h | 119 ++++++ .../test_cryptodev_security_ipsec_test_vectors.h | 321 +++++++++++++++++ doc/guides/rel_notes/release_21_11.rst | 7 + 7 files changed, 1206 insertions(+) create mode 100644 app/test/test_cryptodev_security_ipsec.c create mode 100644 app/test/test_cryptodev_security_ipsec.h create mode 100644 app/test/test_cryptodev_security_ipsec_test_vectors.h -- 2.7.4