HomeFreeBSD

pf: fix more syncookie memory leaks

Description

pf: fix more syncookie memory leaks

Allocate memory for packed nvlists in M_NVLIST, as nvlist_pack() does
this as well, and we use the same variable interchangable with the
memory we allocate. When we free it we can end up freeing from the wrong
zone, leaking memory.

Reviewed by: kp
Differential Revision: https://reviews.freebsd.org/D35385

(cherry picked from commit a37e0e6de6527a7eaddea8e28f5e4b3427fba1a4)

Details

Provenance
franco_opnsense.orgAuthored on Jun 2 2022, 4:27 PM
kpCommitted on Jun 6 2022, 7:01 AM
Reviewer
kp
Differential Revision
D35385: pf: still one leak in here so switch all to M_NVLIST
Parents
rGa015500ef39e: pf syncookies: fix memory leak
Branches
Unknown
Tags
Unknown