All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] net: fix out-of-bounds write in IP fragment reassembly
@ 2026-07-28  6:50 Shahriyar Jalayeri
  2026-07-28  6:50 ` [PATCH v2 1/2] " Shahriyar Jalayeri
  2026-07-28  6:50 ` [PATCH v2 2/2] test: net: add regression test for IP reassembly overflow Shahriyar Jalayeri
  0 siblings, 2 replies; 4+ messages in thread
From: Shahriyar Jalayeri @ 2026-07-28  6:50 UTC (permalink / raw)
  To: u-boot
  Cc: Jerome Forissier, Tom Rini, Wayen Yan, Simon Glass, Argus,
	Shahriyar Jalayeri

This fixes an out-of-bounds write in IP fragment reassembly and adds a
regression test.

__net_defragment() writes an 8-byte hole descriptor that can land past
the end of the static reassembly buffer when a fragment with a non-zero
offset and the More-Fragments flag set is received during netboot. It is
reachable on the local network segment while the device is in a receive
loop (dhcp/tftp/nfs/ping). Patch 1 adds the bounds check; patch 2 adds a
DM test that reproduces the overflow.

Based on v2026.07 (fdfe2ec48d5c).

Signed-off-by: Shahriyar Jalayeri <shahriyar@byteray.co.uk>
---
Changes in v2:
- Use my real name in the From and Signed-off-by (Jerome Forissier)

---
Shahriyar Jalayeri (2):
      net: fix out-of-bounds write in IP fragment reassembly
      test: net: add regression test for IP reassembly overflow

 net/net.c            |  4 ++++
 test/dm/net_defrag.c | 36 ++++++++++++++++++++++++++++++++++++
 2 files changed, 40 insertions(+)
---
base-commit: fdfe2ec48d5c1c2ed03073d73edd3fdd3fe1ffa1
change-id: 20260722-net-oob-fix-4b8fc8adeec6

Best regards,
--  
Shahriyar Jalayeri <shahriyar@byteray.co.uk>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-07-30 13:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-28  6:50 [PATCH v2 0/2] net: fix out-of-bounds write in IP fragment reassembly Shahriyar Jalayeri
2026-07-28  6:50 ` [PATCH v2 1/2] " Shahriyar Jalayeri
2026-07-30 13:28   ` Jerome Forissier
2026-07-28  6:50 ` [PATCH v2 2/2] test: net: add regression test for IP reassembly overflow Shahriyar Jalayeri

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.