Convert firehol lists to nftables sets
All checks were successful
CI / test (push) Successful in 1m9s
Since these are ranges, the counter isn't especially useful. It's also more resources to track |
||
---|---|---|
.forgejo/workflows | ||
.gitignore | ||
example.nft | ||
firehol-nftables.py | ||
justfile | ||
pyproject.toml | ||
README.md | ||
uv.lock |
firehol-nftables
Convert FireHOL IP lists into nftable
sets.
Dependencies
- Python (no dependencies needed outside of the standard library)
Usage
$ firehol-nftables.py <lists> --output <file.nft>
For example:
$ firehol-nftables.py firehol_level1 firehol_level2 firehol_level3 --output /etc/nftables.d/firehol.nft
This command does not reload nftables - that will need to be done separately. That means this script does not require root privileges to run.
The generated file can be loaded nftables, ideally using your main /etc/nftables.conf
file. See example.nft
for an example of loading it.