qwj / python-proxy

HTTP/HTTP2/HTTP3/Socks4/Socks5/Shadowsocks/ShadowsocksR/SSH/Redirect/Pf TCP/UDP asynchronous tunnel proxy implemented in Python 3 asyncio.
MIT License
1.99k stars 333 forks source link

[Question] - How to tunnel through multiple jump server? #146

Open indopay opened 2 years ago

indopay commented 2 years ago

There is a total 4 servers:

A machine is my localhost, IP 127.0.0.1 B server is a http proxy, IP 10.10.10.10 port 1010 C server is a socks5 proxy, IP 10.20.20.20 port 2020 D server it the final destination, IP 10.100.100.100 port 22

I want to listen on machine A 127.0.0.1 port 5555 and all connection to that port should be forwarded (tunneled(?)) to D server 10.100.100.100 port 22 through the B and C servers.

The diagram: diagram

What is the exact command i should type?

I know the tunnel{} syntax from the example but it is only for single direct destination (without jump servers in between).

Thank you!

dhruvrauthan commented 1 year ago

You can use proxychains for this purpose