TransWikia.com

UDP Hole Punching: Unable to send data from server to client (client to server OK)

Super User Asked on December 20, 2021

Starting with server-A (globally reachable via static IP), I bind a UDP socket to 0.0.0.0:25000.

Then with client-A behind a (residential) NAT, I bind a UDP socket to 0.0.0.0:25000. Client-A then sends a packet to server-A.

Server-A receives the packet. Server-A records the remote socket, K, from where the packet was NAT’ed. Server-A sends a packet to K with the intention that the NAT forward the packet to client-A.

However, client-A does not receive the packet. On the NAT, when I enable port triggering on port 25000 for UDP, then it works. However, in the making of a p2p app, I’d prefer to stay away from requiring clients to go into the router settings to make the program work. How can I punch a hole through the firewall such that the communication is bidirectional?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP