1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(C) 2021 Marvell.
5 #ifndef _TEST_CRYPTODEV_SECURITY_IPSEC_H_
6 #define _TEST_CRYPTODEV_SECURITY_IPSEC_H_
8 #include <rte_cryptodev.h>
9 #include <rte_security.h>
11 struct ipsec_test_data {
35 struct rte_security_ipsec_xform ipsec_xform;
41 struct rte_crypto_sym_xform cipher;
42 struct rte_crypto_sym_xform auth;
44 struct rte_crypto_sym_xform aead;
48 int test_ipsec_sec_caps_verify(struct rte_security_ipsec_xform *ipsec_xform,
49 const struct rte_security_capability *sec_cap,
52 int test_ipsec_crypto_caps_aead_verify(
53 const struct rte_security_capability *sec_cap,
54 struct rte_crypto_sym_xform *aead);
56 void test_ipsec_td_in_from_out(const struct ipsec_test_data *td_out,
57 struct ipsec_test_data *td_in);
59 int test_ipsec_post_process(struct rte_mbuf *m,
60 const struct ipsec_test_data *td,
61 struct ipsec_test_data *res_d, bool silent);
63 int test_ipsec_status_check(struct rte_crypto_op *op,
64 enum rte_security_ipsec_sa_direction dir);