iptables -I INPUT -s xxx.xxx.xxx.xxx -j DROP
insert (-i) into chain INPUT with source (-s) ip xxx.xxx.xxx.xxx and jump (-j) to target DROP
iptables -L INPUT
List the entries in the INPUT chain
iptables -F INPUT
Flush the INPUT chain
iptables -L -n**
List by IP address
iptables-save > /etc/iptables.conf
Saves
iptables-restore < /etc/iptables.conf
Restores
use the output chain to drop all requests on port 80
then accept ips that you want
Adding on command line
iptables -I OUTPUT -s 217.158.112.246 -d destinationIP -p tcp --dport 80 -j ACCEPT