opnsense-src/lib/libutil/tests
Kyle Evans f3c488fc6b libutil: avoid an out-of-bounds read in trimdomain(3)
memchr(3) will happily believe we've passed in a valid object, but
hostsize could easily exceed the bounds of fullhost.  Clamp it down to
the string size to be safe and avoid UB.  This plugs a potential
overread noted in the compat shim that was just added.

Reviewed by:	des
Sponsored by:	Klara, Inc.

(cherry picked from commit f268f95955f5f0f91f4d39e13bcd69a24e0d8ce4)
2026-04-23 08:48:43 -05:00
..
cpuset_test.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
expand_number_test.c libutil: Fix 32-bit build 2025-08-07 11:34:13 +02:00
flopen_test.c lib: Automated cleanup of cdefs and other formatting 2023-11-26 22:23:59 -07:00
forkpty_test.c forkpty: Avoid fd leak if fork() fails. 2023-08-17 13:48:42 +00:00
grp_test.c lib: Automated cleanup of cdefs and other formatting 2023-11-26 22:23:59 -07:00
humanize_number_test.c Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:16 -06:00
Makefile Remove residual blank line at start of Makefile 2024-07-15 16:43:39 -06:00
Makefile.depend Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
pidfile_test.c lib: Automated cleanup of cdefs and other formatting 2023-11-26 22:23:59 -07:00
trimdomain-nodomain_test.c include: ssp: round out fortification of current set of headers 2024-07-13 00:16:24 -05:00
trimdomain_test.c libutil: avoid an out-of-bounds read in trimdomain(3) 2026-04-23 08:48:43 -05:00