DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] crypto/cnxk: prevent out of bound access in crypto_caps
@ 2022-04-21  7:58 Gowrishankar Muthukrishnan
  2022-04-21  8:39 ` Anoob Joseph
  0 siblings, 1 reply; 2+ messages in thread
From: Gowrishankar Muthukrishnan @ 2022-04-21  7:58 UTC (permalink / raw)
  To: dev
  Cc: Tejasree Kondoj, Ankur Dwivedi, Anoob Joseph, Archana Muniganti,
	Jerin Jacob, Gowrishankar Muthukrishnan

In a situation where crypto_caps elements are checked only for
RTE_CRYPTO_OP_TYPE_UNDEFINED until valid op defined, there is
possibility for an out of bound access. Add this array by one
element for current capabilities.

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
---
 drivers/crypto/cnxk/cnxk_cryptodev.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/cnxk/cnxk_cryptodev.h b/drivers/crypto/cnxk/cnxk_cryptodev.h
index 16e757283c..e65195ed66 100644
--- a/drivers/crypto/cnxk/cnxk_cryptodev.h
+++ b/drivers/crypto/cnxk/cnxk_cryptodev.h
@@ -10,7 +10,7 @@
 
 #include "roc_cpt.h"
 
-#define CNXK_CPT_MAX_CAPS	 34
+#define CNXK_CPT_MAX_CAPS	 35
 #define CNXK_SEC_CRYPTO_MAX_CAPS 11
 #define CNXK_SEC_MAX_CAPS	 5
 #define CNXK_AE_EC_ID_MAX	 8
-- 
2.25.1


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

* RE: [PATCH] crypto/cnxk: prevent out of bound access in crypto_caps
  2022-04-21  7:58 [PATCH] crypto/cnxk: prevent out of bound access in crypto_caps Gowrishankar Muthukrishnan
@ 2022-04-21  8:39 ` Anoob Joseph
  0 siblings, 0 replies; 2+ messages in thread
From: Anoob Joseph @ 2022-04-21  8:39 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan, dev
  Cc: Tejasree Kondoj, Ankur Dwivedi, Archana Muniganti,
	Jerin Jacob Kollanukkaran, Gowrishankar Muthukrishnan

> 
> In a situation where crypto_caps elements are checked only for
> RTE_CRYPTO_OP_TYPE_UNDEFINED until valid op defined, there is possibility
> for an out of bound access. Add this array by one element for current
> capabilities.
> 
> Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
> ---
>  drivers/crypto/cnxk/cnxk_cryptodev.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 

Acked-by: Anoob Joseph <anoobj@marvell.com>

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

end of thread, other threads:[~2022-04-21  8:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-21  7:58 [PATCH] crypto/cnxk: prevent out of bound access in crypto_caps Gowrishankar Muthukrishnan
2022-04-21  8:39 ` Anoob Joseph

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