Page MenuHomeFreeBSD

pf: address family must be set when creating a pf_fragment
ClosedPublic

Authored by kp on Jun 9 2015, 5:10 PM.
Tags
None
Referenced Files
Unknown Object (File)
Jan 22 2025, 4:31 AM
Unknown Object (File)
Jan 18 2025, 5:48 AM
Unknown Object (File)
Jan 9 2025, 3:56 PM
Unknown Object (File)
Nov 27 2024, 12:40 AM
Unknown Object (File)
Sep 13 2024, 10:10 PM
Unknown Object (File)
Sep 13 2024, 10:10 PM
Unknown Object (File)
Sep 13 2024, 10:10 PM
Unknown Object (File)
Sep 11 2024, 7:57 PM
Subscribers

Details

Reviewers
philip
gnn
Summary

Fix a panic when handling fragmented ip4 packets with 'drop-ovl' set.
In that scenario we take a different branch in pf_normalize_ip(), taking us to pf_fragcache() (rather than pf_reassemble()). In pf_fragcache() we create a pf_fragment, but do not set the address family. This leads to a panic when we try to insert that into pf_frag_tree because pf_addr_cmp(), which is used to compare the pf_fragments doesn't know what to do if the address family is not set.

Simply ensure that the address family is set correctly (always AF_INET in this path).

PR: 200330

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

kp retitled this revision from to pf: address family must be set when creating a pf_fragment.
kp updated this object.
kp edited the test plan for this revision. (Show Details)
kp added reviewers: philip, gnn.
kp set the repository for this revision to rS FreeBSD src repository - subversion.
philip edited edge metadata.

Approved by: philip (mentor)

This revision is now accepted and ready to land.Jun 9 2015, 5:12 PM
gnn edited edge metadata.

Submitted as r284222.