[PATCH v2 0/3] net: dhcp: fix buffer overflows
Sascha Hauer
s.hauer at pengutronix.de
Wed Apr 1 23:59:56 PDT 2026
Fix buffer overflows on malicious incoming network packets or user data
in the dhcp code.
Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
Changes in v2:
- use first character != 0 check instead of strnlen
- Link to v1: https://lore.barebox.org/20260402-net-dhcp-buffer-overflows-v1-0-cd60b651a629@pengutronix.de
---
Sascha Hauer (3):
net: dhcp: add bounds checking to DHCP option parsing
net: dhcp: use xstrndup for bp_file to prevent read past field
net: dhcp: cap DHCP option string length to 255 bytes
net/dhcp.c | 36 +++++++++++++++++++++++++-----------
1 file changed, 25 insertions(+), 11 deletions(-)
---
base-commit: 0933e8f2ebf0d91dfcf177a4e4292b02921a53f1
change-id: 20260402-net-dhcp-buffer-overflows-94a0e80363c1
Best regards,
--
Sascha Hauer <s.hauer at pengutronix.de>
More information about the barebox
mailing list