Page MenuHomeFreeBSD

pf: fix another endpoint-independent crash
ClosedPublic

Authored by kp on Nov 21 2025, 1:24 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Jan 23, 8:23 AM
Unknown Object (File)
Sat, Jan 10, 8:09 AM
Unknown Object (File)
Sat, Jan 10, 4:36 AM
Unknown Object (File)
Fri, Jan 9, 7:18 PM
Unknown Object (File)
Dec 19 2025, 8:05 AM
Unknown Object (File)
Dec 8 2025, 8:10 PM
Unknown Object (File)
Dec 8 2025, 2:47 PM
Unknown Object (File)
Dec 3 2025, 4:00 AM

Details

Summary

In c12013f5bb38 we fixed udp_mapping cleanup issues in pf_get_sport(), but
missed the static-port case (i.e. low == 0 && high == 0). We could still exit
pf_get_sport() without either inserting the udp_mapping or freeing it.

Address this and add a test case to provoke the problem.

MFC after: 1 week
Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable