Name
ipfwadm
Synopsis
ipfwadm category command parameters [options]
ipfwadm -M [ -l | -s ] [options]
Description
Administer a firewall and its rules, firewall accounting, and IP masquerading in the 2.0 Linux kernel. This command is replaced with ipchains in the 2.2 kernel, and ipchains is replaced by iptables in the 2.4 kernel.
There are four categories of rules: IP packet accounting, IP input firewall, IP output firewall, and IP forwarding firewall. The rules are maintained in lists, with a separate list for each category. See the manpage for ipfw(4) for a more detailed description of how the lists work.
Each ipfwadm command specifies only one category and one rule. To create a secure firewall, you issue multiple ipfwadm commands; the combination of their rules work together to ensure that your firewall operates as you intend it to. The second form of the command is for masquerading. The commands -l and -s described in the later list are the only ones that can be used with the masquerading category, -M.
Categories
One of the following flags is required to indicate the category of rules to which the command that follows the category applies.
- -A [direction]
IP accounting rules. Optionally, a direction can be specified:
- in
Count only incoming packets.
- out
Count only outgoing packets.
- both
Count both incoming and outgoing packets; this is the default.
- -F
IP forwarding firewall rules.
- -I
IP input firewall rules.
- -M
IP masquerading administration. Can be used only with the -l or -s command. ...
Get Linux in a Nutshell, Third Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.