My goal is to create a table of addresses and connection limits such that the lookup of an address in the table returns a limit value for connections from that address. The table gets created, but the limit value gets corrupted. To replicate: 1. Create the table: "ipfw table foo create type addr valtype limit" 2. Add a record: "ipfw table foo add 10.10.10.20 3" # ipfw table foo add 10.10.10.20 3 added: 10.10.10.20/32 3 Added value-----------^ # ipfw table foo list 10.10.10.20/32 0 Corrupt value--^ Proceeding anyway... 3. Create a rule "ipfw add 1000 allow udp from 'table(foo)' to me limit src-addr tablearg" The rule is accepted, but it does not allow any traffic to pass due to the corrupted value. The log entry is: Feb 9 14:12:46 firewall kernel: ipfw: 1000 drop session type 40 10.10.10.20 0 -> 0.0.0.0 0, 0 too many entries Additional note: The same corruption happens on a flow table: # ipfw table foo create type flow:src-ip,dst-port valtype limit # # ipfw table foo add 10.10.10.20,5656 3 added: 10.10.10.20,5656 3 # # ipfw table foo list 10.10.10.20,5656 0 #
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=95ab7b3223c08cf48ccf764815523ea995a7ea0e commit 95ab7b3223c08cf48ccf764815523ea995a7ea0e Author: Andrey V. Elsukov <ae@FreeBSD.org> AuthorDate: 2025-02-10 07:58:23 +0000 Commit: Andrey V. Elsukov <ae@FreeBSD.org> CommitDate: 2025-02-10 07:58:23 +0000 ipfw: add missing initializer for 'limit' table value PR: 284691 MFC after: 1 week sys/netpfil/ipfw/ip_fw_table_value.c | 1 + 1 file changed, 1 insertion(+)
^Triage: assign to committer. Set flags for possible MFCs if desired.
A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=09def8d654e7be0454925ab57c4e6e1d1d173911 commit 09def8d654e7be0454925ab57c4e6e1d1d173911 Author: Andrey V. Elsukov <ae@FreeBSD.org> AuthorDate: 2025-02-10 07:58:23 +0000 Commit: Andrey V. Elsukov <ae@FreeBSD.org> CommitDate: 2025-02-17 07:33:59 +0000 ipfw: add missing initializer for 'limit' table value PR: 284691 (cherry picked from commit 95ab7b3223c08cf48ccf764815523ea995a7ea0e) sys/netpfil/ipfw/ip_fw_table_value.c | 1 + 1 file changed, 1 insertion(+)
A commit in branch stable/13 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=ff2588f2ac0a7a4d15496e2654f22d4d300037bf commit ff2588f2ac0a7a4d15496e2654f22d4d300037bf Author: Andrey V. Elsukov <ae@FreeBSD.org> AuthorDate: 2025-02-10 07:58:23 +0000 Commit: Andrey V. Elsukov <ae@FreeBSD.org> CommitDate: 2025-02-17 07:40:29 +0000 ipfw: add missing initializer for 'limit' table value PR: 284691 (cherry picked from commit 95ab7b3223c08cf48ccf764815523ea995a7ea0e) sys/netpfil/ipfw/ip_fw_table_value.c | 1 + 1 file changed, 1 insertion(+)