pfctl: make the source limiter output match the input

When printing source limiters use the same keywords as we accept on
input, that is use 'entries' for the entries value (not 'limit') and
'limit' for the limit value (and not 'states').

Update the test case to match.

Sponsored by:	Rubicon Communications, LLC ("Netgate")
This commit is contained in:
Kristof Provost
2026-01-12 21:32:13 +01:00
parent 8716d8c7d9
commit e28dfd6b55
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -869,7 +869,7 @@ print_statelim(const struct pfctl_state_lim *ioc)
void
print_sourcelim(const struct pfctl_source_lim *ioc)
{
printf("source limiter %s id %u limit %u states %u", ioc->name,
printf("source limiter %s id %u entries %u limit %u", ioc->name,
ioc->id, ioc->entries, ioc->limit);
if (ioc->rate.limit != 0)
printf(" rate %u/%u", ioc->rate.limit, ioc->rate.seconds);
+1 -1
View File
@@ -1,2 +1,2 @@
source limiter dns-server id 1 limit 2 states 3 rate 4/5 inet mask 16
source limiter dns-server id 1 entries 2 limit 3 rate 4/5 inet mask 16
pass in proto tcp from any to any port = domain flags S/SA keep state source limiter id 1 (no-match)