#
b3a68a2e |
| 22-Mar-2025 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCRCLRTSTATS to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
Revision tags: release/13.5.0 |
|
#
9e8d2962 |
| 06-Mar-2025 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCRGETTSTATS to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
Revision tags: release/14.2.0-p2, release/14.1.0-p8, release/13.4.0-p4 |
|
#
07e070ef |
| 07-Feb-2025 |
Kajetan Staszkiewicz <ks@FreeBSD.org> |
pf: Add support for multiple source node types
For every state pf creates up to two source nodes: a limiting one struct pf_kstate -> src_node and a NAT one struct pf_kstate -> nat_src_node. The limi
pf: Add support for multiple source node types
For every state pf creates up to two source nodes: a limiting one struct pf_kstate -> src_node and a NAT one struct pf_kstate -> nat_src_node. The limiting source node is tracking information needed for limits using max-src-states and max-src-nodes and the NAT source node is tracking NAT rules only.
On closer inspection some issues emerge: - For route-to rules the redirection decision is stored in the limiting source node. Thus sticky-address and source limiting can't be used separately. - Global source tracking, as promised in the man page, is totally absent from the code. Pfctl is capable of setting flags PFRULE_SRCTRACK (enable source tracking) and PFRULE_RULESRCTRACK (make source tracking per rule). The kernel code checks PFRULE_SRCTRACK but ignores PFRULE_RULESRCTRACK. That makes source tracking work per-rule only.
This patch is based on OpenBSD approach where source nodes have a type and each state has an array of source node pointers indexed by source node type instead of just two pointers. The conditions for limiting are applied only to source nodes of PF_SN_LIMIT type. For global limit tracking source nodes are attached to the default rule.
Reviewed by: kp Approved by: kp (mentor) Sponsored by: InnoGames GmbH Differential Revision: https://reviews.freebsd.org/D39880
show more ...
|
#
71594e32 |
| 10-Feb-2025 |
Kristof Provost <kp@FreeBSD.org> |
pf: support "!received-on <interface>"
ok dlg benno
Obtained from: OpenBSD, henning <henning@openbsd.org>, 7d0482a910 Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
0d2058ab |
| 07-Feb-2025 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCRDELTABLES to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
84a80eae |
| 07-Feb-2025 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCRADDTABLES to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
Revision tags: release/14.1.0-p7, release/14.2.0-p1, release/13.4.0-p3 |
|
#
0972294e |
| 20-Jan-2025 |
Kristof Provost <kp@FreeBSD.org> |
pf: add a dedicated pf pool for route options
As suggested by henning. Which unbreaks ie route-to after the recent pf changes.
With much help debugging and pointing out of missing bits from claudio
pf: add a dedicated pf pool for route options
As suggested by henning. Which unbreaks ie route-to after the recent pf changes.
With much help debugging and pointing out of missing bits from claudio@
ok claudio@ "looks good" henning@
Obtained from: OpenBSD, jsg <jsg@openbsd.org>, 7fa5c09028 Sponsored by: Rubicon Communications, LLC ("Netgate")
show more ...
|
#
441d4894 |
| 03-Dec-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCRCLRTABLES to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
Revision tags: release/14.2.0 |
|
#
aa69fdf1 |
| 10-Oct-2024 |
Kristof Provost <kp@FreeBSD.org> |
pfctl: change for af-to / NAT64 support.
The general syntax is: pass in inet from any to 192.168.1.1 af-to inet6 from 2001::1 to 2001::2 In the NAT64 case the "to" is not needed in af-to and the IP
pfctl: change for af-to / NAT64 support.
The general syntax is: pass in inet from any to 192.168.1.1 af-to inet6 from 2001::1 to 2001::2 In the NAT64 case the "to" is not needed in af-to and the IP is extraced from the IPv6 dst (assuming a /64 prefix). Again most work by sperreault@, mikeb@ and reyk@ OK mcbride@, put it in deraadt@
Obtained from: OpenBSD, claudio <claudio@openbsd.org>, 0cde32ce3f Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D47790
show more ...
|
#
e11dacbf |
| 11-Oct-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: partially import OpenBSD's NAT rewrite
We won't follow this fully, because it involves breaking syntax changes (removing nat/rdr rules and moving this functionality into regular rules) as well a
pf: partially import OpenBSD's NAT rewrite
We won't follow this fully, because it involves breaking syntax changes (removing nat/rdr rules and moving this functionality into regular rules) as well as behaviour changes because NAT is now done after the rules evaluation, rather than before it.
We import some related changes anyway, because it paves the way for nat64 support. This change introduces a new pf_kpool in struct pf_krule, for nat. It is not yet used (but will be for nat64) and renames the existing 'rpool' to 'rdr'.
Obtained from: OpenBSD, henning <henning@openbsd.org>, 0ef3d4febe Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D47783
show more ...
|
#
9c125336 |
| 11-Oct-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCGETSRCNODES to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
48f5bf8b |
| 03-Oct-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCGETRULESET to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D46938
|
#
25e0f8f9 |
| 01-Oct-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCGETRULESETS to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D46930
|
Revision tags: release/13.4.0 |
|
#
2339ead6 |
| 29-Aug-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: allow filtering on the receive interface
add support to pf for filtering a packet by the interface it was received on. use the received-on IFNAME filter option on a pf.conf rule to restrict whic
pf: allow filtering on the receive interface
add support to pf for filtering a packet by the interface it was received on. use the received-on IFNAME filter option on a pf.conf rule to restrict which packet the interface had to be received on. eg:
pass out on em0 from $foo to $bar received-on fxp0
ive been running this in production for a week now. i find it particularly usefull with interface groups.
no objections, and a few "i like"s from henning, claudio, deraadt, mpf
Obtained from: OpenBSD, dlg <dlg@openbsd.org>, 95b4320893 Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D46577
show more ...
|
#
9ae91f59 |
| 19-Jul-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCGETADDR to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
644b7b5a |
| 19-Jul-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCGETADDRS to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
d909f06b |
| 16-Jul-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCADDADDR to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
ba2a9207 |
| 07-Jun-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCBEGINADDRS to netlink
|
#
d9ab8999 |
| 07-Jun-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: migrate DIOCGETLIMIT/DIOCSETLIMIT to netlink
Event: Kitchener-Waterloo Hackathon 202406
|
#
30bad751 |
| 05-Jun-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCGETTIMEOUT/DIOCSETTIMEOUT to netlink
|
#
c36c90a2 |
| 01-Jun-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCSETDEBUG to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
71d3c704 |
| 31-May-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCNATLOOK to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
Revision tags: release/14.1.0 |
|
#
9dbbe68b |
| 30-May-2024 |
Kristof Provost <kp@FreeBSD.org> |
pf: convert DIOCCLRSTATUS to netlink
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
#
cd2054d4 |
| 24-May-2024 |
Kristof Provost <kp@FreeBSD.org> |
libpfctl: add pfctl_get_rule_h()
Add a handle variant of pfctl_get_rule(). This converts us from using the nvlist variant to the netlink variant, and also moves us closer to a world where all libpfc
libpfctl: add pfctl_get_rule_h()
Add a handle variant of pfctl_get_rule(). This converts us from using the nvlist variant to the netlink variant, and also moves us closer to a world where all libpfctl functions take the handle.
While here have pfctl use the new function.
Sponsored by: Rubicon Communications, LLC ("Netgate")
show more ...
|
#
f1612e70 |
| 09-May-2024 |
Kristof Provost <kp@FreeBSD.org> |
libpfctl: fix file descriptor leak
pfctl_get_rules_info() opened a netlink socket, but failed to close it again. Fix this by factoring out the netlink-based function into a _h variant that takes str
libpfctl: fix file descriptor leak
pfctl_get_rules_info() opened a netlink socket, but failed to close it again. Fix this by factoring out the netlink-based function into a _h variant that takes struct pfctl_handle, and implement pfctl_get_rules_info() based on that, remembering to close the fd.
While here migrate all in-tree consumers to the _h variant.
MFC after: 3 days Sponsored by: Rubicon Communications, LLC ("Netgate")
show more ...
|