DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] examples/l2fwd-crypto: out-of-bounds read
@ 2016-06-29 12:19 Slawomir Mrozowicz
  2016-06-30  9:15 ` Declan Doherty
  0 siblings, 1 reply; 3+ messages in thread
From: Slawomir Mrozowicz @ 2016-06-29 12:19 UTC (permalink / raw)
  To: declan.doherty; +Cc: dev, Slawomir Mrozowicz

Overrunning array crypto_statistics of 32 64-byte elements
at element index 63 using index cdevid.
Fixed by extend crypto_statistics array.

Fixes: 387259bd6c67 ("examples/l2fwd-crypto: add sample application")
Coverity ID 120145

Signed-off-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
---
 examples/l2fwd-crypto/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/l2fwd-crypto/main.c b/examples/l2fwd-crypto/main.c
index 8dc616d..70fada5 100644
--- a/examples/l2fwd-crypto/main.c
+++ b/examples/l2fwd-crypto/main.c
@@ -243,7 +243,7 @@ struct l2fwd_crypto_statistics {
 } __rte_cache_aligned;
 
 struct l2fwd_port_statistics port_statistics[RTE_MAX_ETHPORTS];
-struct l2fwd_crypto_statistics crypto_statistics[RTE_MAX_ETHPORTS];
+struct l2fwd_crypto_statistics crypto_statistics[RTE_CRYPTO_MAX_DEVS];
 
 /* A tsc-based timer responsible for triggering statistics printout */
 #define TIMER_MILLISECOND 2000000ULL /* around 1ms at 2 Ghz */
-- 
1.9.1

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

* Re: [dpdk-dev] [PATCH] examples/l2fwd-crypto: out-of-bounds read
  2016-06-29 12:19 [dpdk-dev] [PATCH] examples/l2fwd-crypto: out-of-bounds read Slawomir Mrozowicz
@ 2016-06-30  9:15 ` Declan Doherty
  2016-07-11 14:50   ` Thomas Monjalon
  0 siblings, 1 reply; 3+ messages in thread
From: Declan Doherty @ 2016-06-30  9:15 UTC (permalink / raw)
  To: Slawomir Mrozowicz; +Cc: dev

On 29/06/16 13:19, Slawomir Mrozowicz wrote:
> Overrunning array crypto_statistics of 32 64-byte elements
> at element index 63 using index cdevid.
> Fixed by extend crypto_statistics array.
>
> Fixes: 387259bd6c67 ("examples/l2fwd-crypto: add sample application")
> Coverity ID 120145
>
> Signed-off-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
> ---
>  examples/l2fwd-crypto/main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/examples/l2fwd-crypto/main.c b/examples/l2fwd-crypto/main.c
> index 8dc616d..70fada5 100644
> --- a/examples/l2fwd-crypto/main.c
> +++ b/examples/l2fwd-crypto/main.c
> @@ -243,7 +243,7 @@ struct l2fwd_crypto_statistics {
>  } __rte_cache_aligned;
>
>  struct l2fwd_port_statistics port_statistics[RTE_MAX_ETHPORTS];
> -struct l2fwd_crypto_statistics crypto_statistics[RTE_MAX_ETHPORTS];
> +struct l2fwd_crypto_statistics crypto_statistics[RTE_CRYPTO_MAX_DEVS];
>
>  /* A tsc-based timer responsible for triggering statistics printout */
>  #define TIMER_MILLISECOND 2000000ULL /* around 1ms at 2 Ghz */
>
Acked-by: Declan Doherty <declan.doherty@intel.com>

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

* Re: [dpdk-dev] [PATCH] examples/l2fwd-crypto: out-of-bounds read
  2016-06-30  9:15 ` Declan Doherty
@ 2016-07-11 14:50   ` Thomas Monjalon
  0 siblings, 0 replies; 3+ messages in thread
From: Thomas Monjalon @ 2016-07-11 14:50 UTC (permalink / raw)
  To: Slawomir Mrozowicz; +Cc: dev, Declan Doherty

> > Overrunning array crypto_statistics of 32 64-byte elements
> > at element index 63 using index cdevid.
> > Fixed by extend crypto_statistics array.
> >
> > Fixes: 387259bd6c67 ("examples/l2fwd-crypto: add sample application")
> > Coverity ID 120145
> >
> > Signed-off-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
> >
> Acked-by: Declan Doherty <declan.doherty@intel.com>

Applied, thanks

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

end of thread, other threads:[~2016-07-11 14:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-29 12:19 [dpdk-dev] [PATCH] examples/l2fwd-crypto: out-of-bounds read Slawomir Mrozowicz
2016-06-30  9:15 ` Declan Doherty
2016-07-11 14:50   ` Thomas Monjalon

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