here you can download/see the manpage of iptables: iptables.man.txt
iptables -L; # -L, --list [chain] # List all rules in the selected chain. # If no chain is selected, all chains are listed. # Like every other iptables command, it applies to the specified table (filter is the default), so NAT rules get listed by iptables -t nat -n -L # Please note that it is often used with the -n option, in order to avoid long reverse DNS lookups. # It is legal to specify the -Z (zero) option as well, in which case the chain(s) will be atomically listed and zeroed. # The exact output is affected by the other arguments given. The exact rules are suppressed until you use iptables -L -v # -S, --list-rules [chain] # Print all rules in the selected chain. If no chain is selected, all chains are printed like iptables-save. # Like every other iptables command, it applies to the specified table (filter is the default).
how to ban / block a single ip:
iptables -L -n # How Do I Unblock An IP Address? # Use the following syntax (the -d options deletes the rule from table): iptables -D INPUT -s xx.xxx.xx.xx -j DROP service iptables save # unblock/unban/delete the rule from table: iptables -d INPUT -s xx.xxx.xx.xx -j DROP service iptables save