2

I have a server exposed to the internet and a personal computer in a private network.

I have an application (Project Zomboid dedicated server) that communicates through UDP ports 16261 and 8766.

I want to be able to listen to those ports in my server and forward the traffic to my personal computer.

My personal computer has Windows 10 and the VPS has Amazon Linux 2

In a TCP escenario I can achieve that executing the following command in my personal computer:

For this example, the server public IP is 123.45.67.89

ssh user@123.45.67.89 -R 0.0.0.0:16261:127.0.0.1:16261 -R 0.0.0.0:8766:127.0.0.1:8766

My question is, how can I achieve the same behavior for UDP protocol?

Clamari
  • 131

2 Answers2

4

The following free and open-source project might solve your problem.

reverse-tunnel rtun is described as:

Reverse tunnel TCP and UDP

rtun is a tool for exposing TCP and UDP ports to the Internet via a public gateway server. You can expose ssh and mosh server on a machine behind firewall and NAT.

harrymc
  • 498,455
0

The UDP reverse tunnel by the author of TorChat does the job.

It simply does the following using UDP hole punching technique:

[Private] <--UDP-- [NAT] <--UDP-- [Public]

You can achieve the same result with port forwarding at NAT level and UDP packets forwarding at the Public Server, though.

In my case I have no access to NAT layer, so this tool came handy to receive an UDP traffic from Gstreamer.

Dmitry
  • 111