Re: [PATCH net] ipv6: ndisc: fix NULL deref in accept_untracked_na()

From: Jiayuan Chen

Date: Thu Jun 18 2026 - 00:09:40 EST



On 6/17/26 9:38 PM, Weiming Shi wrote:
On Wed Jun 17, 2026 at 4:32 PM CST, Jiayuan Chen wrote:
On 6/17/26 2:55 PM, Weiming Shi wrote:
accept_untracked_na() re-fetches the inet6_dev with __in6_dev_get(dev)
and dereferences idev->cnf.accept_untracked_na without a NULL check,

Does ipv6_rpl_srh_rcv have same problem?
Hi,

Yes, ipv6_rpl_srh_rcv() has the same missing check. It reads
idev->cnf.rpl_seg_enabled right after __in6_dev_get(skb->dev) with no
NULL check, while seg6 and ioam6 in the same file both check it.

But I tried to trigger it and couldn't. With a guard added as an instrument,
idev never came back NULL over tens of millions of RPL packets while
flapping the MTU, so I can't say it's actually reachable.


Can you need to add mdelay to enlarge the race window to reproduce it?

I believe we need more precise traffic and timing control, instead of
aggressively ramping up traffic and load in an attempt to reproduce the issue.