OK. I see.
You should get more familiar with SSH and Forwardings.
This is a good start I think:
https://help.ubuntu.com/community/SSH/OpenSSH/PortForwarding
What you want is DynamicForwarding, but HttpWebRequest/HttpWebResponse does not support SOCKS-Proxies.
So you have to check for another way to use your DynamicForwarding in Code as proxy.
You should get more familiar with SSH and Forwardings.
This is a good start I think:
https://help.ubuntu.com/community/SSH/OpenSSH/PortForwarding
What you want is DynamicForwarding, but HttpWebRequest/HttpWebResponse does not support SOCKS-Proxies.
So you have to check for another way to use your DynamicForwarding in Code as proxy.