opnsense-src/sbin/pfctl
Kristof Provost 288bec2b2b pf: fold pf_test_fragment() into pf_test_rule()
Reduces code and fixes a bunch of bugs with fragment handling not being in sync
with the rest of the ruleset.

Much feedback from mpf, bluhm & markus
Thanks to Tony Sarendal for help with testing

ok bluhm; various previous versions ok henning, claudio, mpf, markus

Note that while this changes the order of src addr/src port/dst addr/dst port
skips this doesn't actually affect the kernel/userspace ABI. The kernel always
recalculates skip steps. As a result we have to fix one of the pfctl parser
tests. Note that this is an order change that does not affect what packets are
acceppted or dropped.

Obtained from:	OpenBSD, mcbride <mcbride@openbsd.org>, 04c69899a7
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46705
2024-10-01 09:55:13 +02:00
..
tests pf: fold pf_test_fragment() into pf_test_rule() 2024-10-01 09:55:13 +02: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
parse.y pf: fold pf_test_fragment() into pf_test_rule() 2024-10-01 09:55:13 +02:00
pf.os Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
pf_print_state.c pfctl: improve bitmask printing 2024-09-19 22:20:12 +02:00
pf_ruleset.c sbin: Automated cleanup of cdefs and other formatting 2023-11-26 22:23:59 -07:00
pfctl.8 pfctl: Allow a semicolon (;) as a comment 2024-07-25 15:06:24 +02:00
pfctl.c pfctl: pfik_ifp is always NULL 2024-08-19 18:02:15 +02:00
pfctl.h pf: add a way to list creator ids 2023-10-10 11:48:21 +02:00
pfctl_altq.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
pfctl_ioctl.h pfctl: Move ioctl abstraction functions into libpfctl 2021-04-10 11:16:02 +02:00
pfctl_optimize.c pf: fold pf_test_fragment() into pf_test_rule() 2024-10-01 09:55:13 +02:00
pfctl_osfp.c sbin: Automated cleanup of cdefs and other formatting 2023-11-26 22:23:59 -07:00
pfctl_parser.c pf: add a new log opt PF_LOG_MATCHES 2024-09-19 22:20:13 +02:00
pfctl_parser.h pfctl: fix incorrect optimization 2024-09-16 13:48:49 +02:00
pfctl_qstats.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
pfctl_radix.c pfctl: Allow a semicolon (;) as a comment 2024-07-25 15:06:24 +02:00
pfctl_table.c sbin: Automated cleanup of cdefs and other formatting 2023-11-26 22:23:59 -07:00