firewall - How can I programatically manage pf rules on the fly? -


i need query, modify, add , delete rules. haven't found api's doing this.

the closest i've found pfctl tool using pfctl -s , and pfctl -f dump rules, modify the, , readd them. solution i've considered regenerating entire ruleset , track changes separately. need careful drop few packets possible.

an api in c great; libraries in language fine too.

there no "official" api, can take @ pfctl source code , see how interfaces kernel.


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -