MCPcopy Create free account
hub / github.com/F-Stack/f-stack / crypto_caps_auth_verify

Function crypto_caps_auth_verify

dpdk/app/test/test_pdcp.c:481–500  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

479}
480
481static int
482crypto_caps_auth_verify(uint8_t dev_id, const struct rte_crypto_sym_xform *a_xfrm)
483{
484 const struct rte_cryptodev_symmetric_capability *cap;
485 struct rte_cryptodev_sym_capability_idx cap_idx;
486 int ret;
487
488 cap_idx.type = RTE_CRYPTO_SYM_XFORM_AUTH;
489 cap_idx.algo.auth = a_xfrm->auth.algo;
490
491 cap = rte_cryptodev_sym_capability_get(dev_id, &cap_idx);
492 if (cap == NULL)
493 return -1;
494
495 ret = rte_cryptodev_sym_capability_check_auth(cap, a_xfrm->auth.key.length,
496 a_xfrm->auth.digest_length,
497 a_xfrm->auth.iv.length);
498
499 return ret;
500}
501
502static int
503cryptodev_id_get(bool is_integrity_protected, const struct rte_crypto_sym_xform *c_xfrm,

Callers 1

cryptodev_id_getFunction · 0.85

Tested by

no test coverage detected