Here is a problem:
I have complete ssh
access to two machines on the local intranet.
On machine two quick and reliable internet access.
I want to forward all outgoing traffic from machine PC1 via PC2 in order to speed up internet connection.
Can be this achieved with iptables
?
Here are some facts about situation
- There is no need for PC1 to access other machines in its network or event in intranet at all
- PC1 and PC2 can easily communicate with each other without restrictions (ping, ssh, tcp, udp)
- I cannot use gw2 as PC1 gateway because it's on other network and inaccessible
- I can set up both PC1 and PC2 as necessary