Redirecting ports (NAT) to another machine on a Cisco router

This article was first written in April 2004 for
the BeezNest technical website (http://glasnost.beeznest.org/articles/121)
Log into the machine (using telnet for example). Change to enable mode. Change to configuration terminal mode:
# conf term
Issue the following command to redirect port 22/tcp from the outside interface (address) to the inside machine you would like the connection to get to:
(config)# ip nat inside source static tcp 192.168.0.7 22 222.221.220.68 22
First IP is the inside local IP address (inside the LAN, only reachable locally, so interna

HOWTO Activate NAT on Debian

This article is incomplete and was first written in September 2006
for the BeezNest technical website (http://glasnost.beeznest.org/articles/343).
An example on how to activate NAT on a Debian box (on Etch and up). First, activate IP forwarding in /etc/sysctl.conf. Then, you need to activate NAT itself in /etc/network/interfaces:
auto eth0
iface eth0 inet static
        address 192.168.1.254
        netmask 255.255.255.0
        network 192.168.1.255
        up iptables -t nat -A POSTROUTING -o $IFACE -j MASQUERADE
There you are.