Netdev List
 help / color / mirror / Atom feed
From: Ido Schimmel <idosch@nvidia.com>
To: Ren Wei <weir@nebusec.ai>
Cc: netdev@vger.kernel.org, dsahern@kernel.org, davem@davemloft.net,
	edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
	horms@kernel.org, jiri@resnulli.us, vega@nebusec.ai,
	milkory@outlook.com
Subject: Re: [PATCH net v2 1/1] net: arp: terminate device name before lookup
Date: Mon, 21 Sep 2026 12:31:31 +0300	[thread overview]
Message-ID: <20260921093131.GB2103061@shredder> (raw)
In-Reply-To: <fabf02a70787d17299e4b3153eadffaf20d154b3.1789910973.git.milkory@outlook.com>

On Mon, Sep 21, 2026 at 01:36:19AM +0800, Ren Wei wrote:
> From: Zijie Huang <milkory@outlook.com>
> 
> The ARP ioctl copies a user-provided struct arpreq into a stack object. Its
> arp_dev field may contain IFNAMSIZ bytes without a NUL terminator.
> 
> Such input is passed to dev_get_by_name_rcu() or __dev_get_by_name(), where
> strcmp() can read past the end of the stack object when a matching
> alternative interface name exists.
> 
> Terminate the field before the lookup to prevent the out-of-bounds read.
> 
> Fixes: 36fbf1e52bd3 ("net: rtnetlink: add linkprop commands to add and delete alternative ifnames")
> Cc: stable@vger.kernel.org
> Reported-by: Vega <vega@nebusec.ai>
> Assisted-by: LLM
> Signed-off-by: Zijie Huang <milkory@outlook.com>
> Signed-off-by: Ren Wei <weir@nebusec.ai>

Reviewed-by: Ido Schimmel <idosch@nvidia.com>

  reply	other threads:[~2026-09-21  9:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-20 17:36 [PATCH net v2 0/1] net: arp: fix stack out-of-bounds read via unterminated device name Ren Wei
2026-09-20 17:36 ` [PATCH net v2 1/1] net: arp: terminate device name before lookup Ren Wei
2026-09-21  9:31   ` Ido Schimmel [this message]
2026-09-24  2:10 ` [PATCH net v2 0/1] net: arp: fix stack out-of-bounds read via unterminated device name patchwork-bot+netdevbpf

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=20260921093131.GB2103061@shredder \
    --to=idosch@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=jiri@resnulli.us \
    --cc=kuba@kernel.org \
    --cc=milkory@outlook.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=vega@nebusec.ai \
    --cc=weir@nebusec.ai \
    /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