Skip to content

This attempts to be a didactic implementation towards the UDP hole punching technique, in Typescript for NodeJS

License

Notifications You must be signed in to change notification settings

leandrogenas/udp-punching-ts

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Node UDP Hole punching

In this experiment it is attempted to use the UDP Hole punching technique to initiate a connection between two clients behind NAT (without port forwarding).

Goals

The first goal is to create a simple script that allows sending UDP packets from client to client, in both directions (current state). Future goals include the development of a library that offers this method in a more extensible manner.

Theory

Usage

A public machine acts as a rendezvous server (running rendezvous.js), two clients behind NAT start client.js. A client can ask the rendezvous server to help them him to connect to another client using the TCP hole punching procedure.

  1. Server node rendezvous.js

  2. Client A node client.js [server] [nameA]

  3. Client B node client.js [server] [nameB] [nameA]

About

This attempts to be a didactic implementation towards the UDP hole punching technique, in Typescript for NodeJS

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 100.0%