[PATCH 0/3] net: use strnstr() for lwip_strnstr()
Heinrich Schuchardt
heinrich.schuchardt at canonical.com
Sat Jan 4 00:21:15 CET 2025
Using strstr() instead of strnstr() creates a security concern.
* Implement missing library function strnstr() and add unit tests.
* Use it for lwIP.
Heinrich Schuchardt (3):
lib: implement strnstr()
test: unit tests for strstr() and strnstr()
net: use strnstr() for lwip_strnstr()
include/linux/string.h | 3 +++
lib/lwip/u-boot/arch/cc.h | 2 +-
lib/string.c | 49 +++++++++++++++++++++++++++------------
test/lib/string.c | 40 ++++++++++++++++++++++++++++++++
4 files changed, 78 insertions(+), 16 deletions(-)
--
2.47.1
More information about the U-Boot
mailing list