Two Network cards and ip forwarding
Sounds as if you are configuring a router.
You only need to make a few changes to enable IP forwarding
Enable IP forwarding
echo 1 > /proc/sys/net/ipv4/ip_forward
Configure iptables
sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
sudo iptables -A FORWARD -i eth0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
sudo iptables -A FORWARD -i eth1 -o eth0 -j ACCEPT
See also Ubuntu Wiki router
You will likely want to learn a little about iptables
Linux Firewalls Using IPTables
If all that seems a bit overwhelming, may I suggest you consider one of the linux distributions that are built to act as a router ? I like smoothwall, but there are others to choose from.
smoothwall
Firewall specific distros will handle most or all of the configuration for you and most come with a web based interface to make it ever easier.