iptables for the average desktop user
The Best guide for learning the basics of iptables is here Linux 2.4 Stateful firewall design for the most part it continues to apply to the 2.6 kernel. The only things that won’t apply to your linux system will be: emerge if you aren’t on gentoo, and the kernel options which have changed since 2.4 and even a couple of times during 2.6.
I’m not going to cover those here. If you need help building your kernel or installing iptables I suggest that you consult with either the iptables home page or even better your distribution.