From: Stephen Hemminger <stephen@networkplumber.org>
To: Denis Sergeev <denserg.edu@gmail.com>
Cc: dev@dpdk.org, shepard.siegel@atomicrules.com,
ed.czeck@atomicrules.com, john.miller@atomicrules.com,
sdl.dpdk@linuxtesting.org
Subject: Re: [PATCH] net/ark: validate IPv4 octets in address parser
Date: Wed, 3 Jun 2026 10:29:37 -0700 [thread overview]
Message-ID: <20260603102937.33b3fc9c@phoenix.local> (raw)
In-Reply-To: <20260603054742.120101-1-denserg.edu@gmail.com>
On Wed, 3 Jun 2026 08:47:38 +0300
Denis Sergeev <denserg.edu@gmail.com> wrote:
> The IPv4 parsing helper used by pktgen and pktchkr reads each octet
> with "%u". This allows values above 255 to be accepted from the
> configuration file and encoded into unintended device register values.
>
> Reject parsed octets outside the IPv4 byte range before assembling
> the 32-bit address.
>
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
>
> Fixes: 9c7188a68d7b ("net/ark: provide API for hardware modules pktchkr and pktgen")
>
> Signed-off-by: Denis Sergeev <denserg.edu@gmail.com>
> ---
Have to ask, why a driver is rolling it own IP address parser, that is a bad idea.
But then the whole builtin vendor pktgen in a driver is bad idea.
Claude scan of the driver found lots more issues.
Hate to think what Mythos would find here...
next prev parent reply other threads:[~2026-06-03 17:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-03 5:47 [PATCH] net/ark: validate IPv4 octets in address parser Denis Sergeev
2026-06-03 17:29 ` Stephen Hemminger [this message]
2026-06-04 3:48 ` [PATCH v2] net/ark: use standard IPv4 " Denis Sergeev
2026-06-04 16:55 ` Stephen Hemminger
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=20260603102937.33b3fc9c@phoenix.local \
--to=stephen@networkplumber.org \
--cc=denserg.edu@gmail.com \
--cc=dev@dpdk.org \
--cc=ed.czeck@atomicrules.com \
--cc=john.miller@atomicrules.com \
--cc=sdl.dpdk@linuxtesting.org \
--cc=shepard.siegel@atomicrules.com \
/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