Thread (3 messages) flat view 3 messages, 2 authors, 1d ago

Re: [PATCH] net: prestera: validate num_counters in counter response

From: Paolo Abeni <pabeni@redhat.com>
Date: 2026-09-07 09:03:26

On 9/7/26 5:22 AM, Aamir Ahmed wrote:
prestera_hw_counters_get() iterates over resp->num_counters
entries from the firmware response without verifying it does
not exceed the number of entries requested. A firmware response
claiming more counters than requested causes out-of-bounds reads
from the response buffer and out-of-bounds writes to the caller
stats array.

Validate that num_counters does not exceed the requested count
before iterating.

Fixes: 6e36c7bcb461 ("net: prestera: add counter HW API")
Signed-off-by: Aamir Ahmed <redacted>
Patchwork shows more than 20 patches from you in flight. Please read

Documentation/process/maintainer-netdev.rst

carefully, especially the section about the 15 patches limit.

Stop sending new patches until are the pending ones are processed.

Processing for the pending ones will be likely significantly delayed.

/P
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help