ProxyVM (ubuntu 20.04) creates virtual interface for incoming connections from each VM connected. Like
vif11.0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 10.137.0.9 netmask 255.255.255.255 broadcast 0.0.0.0
inet6 fe80::fcff:ffff:feff:ffff prefixlen 64 scopeid 0x20<link>
ether fe:ff:ff:ff:ff:ff txqueuelen 32 (Ethernet)
RX packets 2123 bytes 730737 (730.7 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 3263 bytes 2818605 (2.8 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
But all the connections just goes to eth0
(I guess…). Task is to redirect them in localhost:port.
I looked up gw-15 iptables rules for a clue, but didn’t understood a thing.
There’s a community guide on VPN setup, that includes some iptables rule management, but it covers only killswitch\failprotection and name servers setup. I can’t see normal redirection rules in it (probably cause openvpn
service does it?).
There’s tinyproxy
mention in gw-15 iptables rules (end of nat table), but that’s only a http(s) proxy, not a tcp.