From: Fan Zhang <roy.fan.zhang@intel.com>
To: dev@dpdk.org
Cc: akhil.goyal@nxp.com, Fan Zhang <roy.fan.zhang@intel.com>
Subject: [dpdk-dev] [PATCH 2/2] fips_validation: fix gcm test
Date: Thu, 22 Oct 2020 10:57:58 +0100 [thread overview]
Message-ID: <20201022095758.587755-3-roy.fan.zhang@intel.com> (raw)
In-Reply-To: <20201022095758.587755-1-roy.fan.zhang@intel.com>
This patch fixes FIPS GCM test of the redundant plaintext string
write and insufficient test case support check for some corner
cases.
Fixes: d09abf2d1007 ("examples/fips_validation: update GCM test")
Cc: roy.fan.zhang@intel.com
Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
---
examples/fips_validation/fips_validation_gcm.c | 1 -
examples/fips_validation/main.c | 10 +++++++---
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/examples/fips_validation/fips_validation_gcm.c b/examples/fips_validation/fips_validation_gcm.c
index df3caa267..250d09bf9 100644
--- a/examples/fips_validation/fips_validation_gcm.c
+++ b/examples/fips_validation/fips_validation_gcm.c
@@ -175,7 +175,6 @@ parse_test_gcm_writeback(struct fips_val *val)
if (vec.status == RTE_CRYPTO_OP_STATUS_SUCCESS) {
fprintf(info.fp_wr, "%s", PT_STR);
if (!info.interim_info.gcm_data.is_gmac) {
- fprintf(info.fp_wr, "%s", PT_STR);
tmp_val.val = val->val;
tmp_val.len = vec.pt.len;
diff --git a/examples/fips_validation/main.c b/examples/fips_validation/main.c
index 07532c956..f3678f056 100644
--- a/examples/fips_validation/main.c
+++ b/examples/fips_validation/main.c
@@ -927,10 +927,14 @@ prepare_gmac_xform(struct rte_crypto_sym_xform *xform)
if (rte_cryptodev_sym_capability_check_auth(cap,
auth_xform->key.length,
- auth_xform->digest_length, 0) != 0) {
- RTE_LOG(ERR, USER1, "PMD %s key length %u IV length %u\n",
+ auth_xform->digest_length,
+ auth_xform->iv.length) != 0) {
+
+ RTE_LOG(ERR, USER1,
+ "PMD %s key length %u Digest length %u IV length %u\n",
info.device_name, auth_xform->key.length,
- auth_xform->digest_length);
+ auth_xform->digest_length,
+ auth_xform->iv.length);
return -EPERM;
}
--
2.26.2
next prev parent reply other threads:[~2020-10-22 9:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-22 9:57 [dpdk-dev] [PATCH 0/2] fips_validation: fix issues Fan Zhang
2020-10-22 9:57 ` [dpdk-dev] [PATCH 1/2] fips_validation: fix missed version line Fan Zhang
2020-10-22 9:57 ` Fan Zhang [this message]
2021-01-14 15:12 ` [dpdk-dev] [PATCH 2/2] fips_validation: fix gcm test Akhil Goyal
2020-10-28 11:44 ` [dpdk-dev] [PATCH 0/2] fips_validation: fix issues Akhil Goyal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201022095758.587755-3-roy.fan.zhang@intel.com \
--to=roy.fan.zhang@intel.com \
--cc=akhil.goyal@nxp.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).