Skip to main content
Kill -9 Club
Sign in

nft

NetworkPackage: nftablesHandle with care

The nftables firewall tool, which replaces iptables. nft list ruleset shows the whole set of rules actually loaded, whichever tool put them there — ufw included.

A mistake with this command can destroy data or lock you out

  • nft flush ruleset removes every rule at once, ufw's included. On a remote machine, check the default policy is not drop before flushing anything.

What its options do in the lessons

From the same glossary the lessons render under their commands, so the two cannot disagree.

nft -a
Adds each rule's internal number, its handle, to the output. That number, and not the position, is what names a rule for deletion.

Lessons that teach it