The quick answer is...
echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -I POSTROUTING -o eth~ -j MASQUERADE
where ~ is your cable modem eth device.
Make sure the router ip number and the Linux box number are in the same subnet, eg
192.168.0.1 & 192.168.0.2 Subnet 255.255.255.252
and the other side of the router is different, eg
192.168.1.~
That's the minimum, no security, no filtering or protection... to let people browse out.
See this
masquerade HOWTO &
tutorial for some extra guidance.