patches for DPDK stable branches
 help / color / mirror / Atom feed
* [PATCH v1] examples/fips_validation: fix IV generation for gmac
@ 2022-11-02 12:01 Brian Dooley
  2022-11-03 11:22 ` [EXT] " Akhil Goyal
  0 siblings, 1 reply; 2+ messages in thread
From: Brian Dooley @ 2022-11-02 12:01 UTC (permalink / raw)
  To: Brian Dooley; +Cc: dev, stable, gakhil

Replace rand() call in fips validation example with rte_rand().

Coverity issue: 381668
Fixes: e27268bd2103 ("examples/fips_validation: add parsing for AES-GMAC")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
---
 examples/fips_validation/main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/examples/fips_validation/main.c b/examples/fips_validation/main.c
index 40a5b70e07..404a29d7b6 100644
--- a/examples/fips_validation/main.c
+++ b/examples/fips_validation/main.c
@@ -12,6 +12,7 @@
 #include <rte_mempool.h>
 #include <rte_mbuf.h>
 #include <rte_string_fns.h>
+#include <rte_random.h>
 
 #include "fips_validation.h"
 #include "fips_dev_self_test.h"
@@ -761,7 +762,7 @@ prepare_auth_op(void)
 		}
 
 		for (i = 0; i < vec.iv.len; i++) {
-			int random = rand();
+			int random = rte_rand();
 			vec.iv.val[i] = (uint8_t)random;
 		}
 	}
-- 
2.25.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* RE: [EXT] [PATCH v1] examples/fips_validation: fix IV generation for gmac
  2022-11-02 12:01 [PATCH v1] examples/fips_validation: fix IV generation for gmac Brian Dooley
@ 2022-11-03 11:22 ` Akhil Goyal
  0 siblings, 0 replies; 2+ messages in thread
From: Akhil Goyal @ 2022-11-03 11:22 UTC (permalink / raw)
  To: Brian Dooley; +Cc: dev, stable

> Replace rand() call in fips validation example with rte_rand().
> 
> Coverity issue: 381668
> Fixes: e27268bd2103 ("examples/fips_validation: add parsing for AES-GMAC")
> 
> Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Applied to dpdk-next-crypto

Thanks.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-11-03 11:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-02 12:01 [PATCH v1] examples/fips_validation: fix IV generation for gmac Brian Dooley
2022-11-03 11:22 ` [EXT] " Akhil Goyal

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).