From: Vadim Fedorenko <vadim.fedorenko@linux.dev>
To: "Marc Suñé" <marcdevel@gmail.com>,
kuba@kernel.org, willemdebruijn.kernel@gmail.com,
pabeni@redhat.com
Cc: netdev@vger.kernel.org, dborkman@kernel.org
Subject: Re: [PATCH net-next v3 1/4] arp: discard invalid sha addr (b/mcast ARP poison)
Date: Thu, 5 Feb 2026 10:54:59 +0000 [thread overview]
Message-ID: <731d97df-a17e-4f9b-8746-d6281d8d53b4@linux.dev> (raw)
In-Reply-To: <d51bdc5aa3236ec4b7cc98c9d6a098f27f45477f.1770241104.git.marcdevel@gmail.com>
On 04/02/2026 22:11, Marc Suñé wrote:
> Prior to this commit, the ARP implementation accepted ARP req/replies
> with multicast (including broadcast) and null MAC addresses as Sender
> HW Address (SHA), and updated the ARP cache for that neighbour.
> Broadcast, multicast and null MAC addresses shall never be associated
> with a unicast or a multicast IPv4 address (see RFC1812, section 3.3.2).
>
> ARP poisioning with a broadcast MAC address and certain multicast
> addresses, especially when poisoning a Gateway IP, have some undesired
> implications compared to an ARP poisioning with a regular MAC (see
> Note1).
>
> Worth mentioning that if an attacker is able to ARP poison in
> a L2 segment, that in itself is probably a bigger security threat
> (Man-in-middle etc., see Note2).
>
> However, since these MACs should never be announced as SHA,
> discard/drop ARPs with SHA={b/mcast, null}, which prevents the
> broadcast/multicast ARP poisoning vector.
>
> Note1:
>
> After a successful broadcast/multicast ARP poisioning attack:
>
> 1. Unicast packets and refresh ("targeted") ARPs sent to or via
> the poisioned IP (e.g. the default GW) are flooded by
> bridges/switches. That is in absence of other security controls.
>
> Hardware swiches generally have rate-limits to prevent/mitigate
> broadcast storms, since ARPs are usually answered by the CPU.
> Legit unicast packets could be dropped (perf. degradation).
>
> Most modern NICs implement some form of L2 MAC filtering to early
> discard irrelevant packets. In contrast to an ARP poisoning
> attack with any other MAC, both unicast and ARP ("targeted")
> refresh packets are passed up to the Kernel networking stack
> (for all hosts in the L2 segment).
>
> 2. A single forged ARP packet (e.g. for the Gateway IP) can produce
> up to N "targeted" (to broadcast) ARPs, where N is the number of
> hosts in the L2 segment that have an ARP entry for that IP
> (e.g. GW), and some more traffic, since the real host will answer
> to targeted refresh ARPs with their (real) reply.
>
> This is a relatively low amount of traffic compared to 1).
>
> 3. An attacker could use this form of ARP poisoning to discover
> all hosts in a L2 segment in a very short period of time with
> one or few packets.
>
> By poisoning e.g. the default GW (likely multiple times, to
> avoid races with real gARPs from the GW), all hosts will eventually
> issue refresh "targeted" ARPs for the GW IP with the broadcast MAC
> address as destination. These packets will be flooded in the L2
> segment, revealing the presence of hosts to the attacker.
>
> For comparison:
> * Passive ARP monitoring: also stealthy, but can take a long
> time or not be possible at all in switches, as most refresh
> ARPs are targeted.
> * ARP req flooding: requires swiping the entire subnet. Noisy
> and easy to detect.
> * ICMP/L4 port scans: similar to the above.
>
> 4. In the unlikely case that hosts were to run with
> `/proc/sys/net/ipv4/conf/*/arp_accept=1` (unsafe, and disabled
> by default), poisoning with the broadcast MAC could be used to
> create significantly more broadcast traffic (low-volume
> amplification attack).
>
> An attacker could send M fake gARP with a number of IP addresses,
> where M is `/proc/sys/net/ipv4/neigh/*/gc_thresh3` (1024 by
> default). This would result in M x R ARPs, where R is the number
> of hosts in L2 segment with `arp_accept=1`, and likely other
> (real) ARP replies coming from the attacked host. This starts to
> get really relevant when R > 512, which is possible in large LANs
> but not very common.
>
> Note2:
>
> However, broadcast ARP poisoning might be subtle and difficult to
> spot. These ARP packets appear on the surface as regular broadcast
> ARP requests (unless ARP hdr is inspected), traffic continues to
> flow uninterrupted (unless broadcast rate-limit in switches kick-in)
> and, the next refresh ARP reply (from the GW) or any (valid) gARP
> from the GW, will restore the original MAC in the ARP table, making
> the traffic flow normally again.
>
> Signed-off-by: Marc Suñé <marcdevel@gmail.com>
Reviewed-by: Vadim Fedorenko <vadim.fedorenko@linux.dev>
next prev parent reply other threads:[~2026-02-05 10:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-04 22:11 [PATCH net-next v3 0/4] discard ARP/NDP b/mcast/null announce (poison) Marc Suñé
2026-02-04 22:11 ` [PATCH net-next v3 1/4] arp: discard invalid sha addr (b/mcast ARP poison) Marc Suñé
2026-02-05 10:54 ` Vadim Fedorenko [this message]
2026-02-04 22:11 ` [PATCH net-next v3 2/4] selftests/net: add no ARP b/mcast,null poison test Marc Suñé
2026-02-04 22:12 ` [PATCH net-next v3 3/4] neigh: discard invalid lladdr (b/mcast poison) Marc Suñé
2026-02-04 22:12 ` [PATCH net-next v3 4/4] selftests/net: add no NDP b/mcast,null poison test Marc Suñé
2026-02-06 2:31 ` [PATCH net-next v3 0/4] discard ARP/NDP b/mcast/null announce (poison) Jakub Kicinski
2026-02-06 14:23 ` Marc Sune
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=731d97df-a17e-4f9b-8746-d6281d8d53b4@linux.dev \
--to=vadim.fedorenko@linux.dev \
--cc=dborkman@kernel.org \
--cc=kuba@kernel.org \
--cc=marcdevel@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=willemdebruijn.kernel@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.