HomeFreeBSD

libpfctl: Fix displaying deeply nested anchors

Description

libpfctl: Fix displaying deeply nested anchors

Set the number of rulesets (i.e., anchors) directly attached to the
anchor and its path in pfctl_get_ruleset().

While here, add a test to document this behavior.

PR: 290478
Reviewed by: kp
Fixes: 041ce1d690f1 ("pfctl: recursively flush rules and tables")
MFC after: 2 days
Differential Revision: https://reviews.freebsd.org/D53358

(cherry picked from commit a943a96a50ba7e9d1e1935bdd18df0e11d158acb)

Details

Provenance
jlduranAuthored on Oct 25 2025, 9:19 AM
Reviewer
rG041ce1d690f1: pfctl: recursively flush rules and tables
Differential Revision
D53358: libpfctl: Fix displaying deeply nested anchors
Parents
rG7af5c1da2887: blocklist: Fix rcorder(8)
Branches
Unknown
Tags
Unknown