Ipset is created without counters even if counters setting is enabled in Luci/Uci.
Nobody has claimed this yet.
- Dominant language
- ucode
- Stars
- 27
- Forks
- 37
- PR merge metrics
- No merged PRs in 30d
Description
Create an ipset in Luci or Uci with counters enabled (Luci) or counters='1' (UCI). Save and apply. Reboot the router. Created ipset has no counters, e.g. nft list set inet fw4 myset returns
table inet fw4 {
set myset {
type ipv4_addr
flags interval
auto-merge
}
}
but should return
table inet fw4 {
set myset {
type ipv4_addr
flags interval
counter
auto-merge
}
}
As I see there is no code that handles counters for ipsets in /usr/share/firewall4/templates/ruleset.uc, e.g.
{% if (set.counters): %}
counter
{% endif %}
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in /usr/share/firewall4/templates/ruleset.uc and trace how ipset definitions are rendered when counters are enabled through LuCI or UCI. Reproduce the configuration, reboot, and run nft list set inet fw4 myset; done means the generated set includes counter when the counters setting is enabled.
Written by the indexing model from the issue text.
Assessment
- Domain
- networking, security
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100