[Gambas-user] UDP hole punching

Mayost Sharon sharon at 455.co.il
Fri Jun 4 13:19:48 CEST 2021


Yes that's how it works

In TCP it seems more complicated
Because in our tools within GAMBAS it is not possible to send to the destination and the remote port before you create a connection.
Or maybe it's not related to GAMBAS
Because that's how TCP works

But I have seen articles that say yes it can be done directly through IPV4 

---------- Original Message -----------
From: John Dovey <dovey.john at gmail.com>
To: Gambas Mailing List <user at lists.gambas-basic.org>
Sent: Thu, 3 Jun 2021 23:13:17 -0500
Subject: Re: [Gambas-user] UDP hole punching

> > I am attaching a demo that shows it works beautifully.
> 
> yYes it does!! Thank you, tested it and I could get two clients, each
> behind their own NAT, to send and receive data via UDP.
> 
> >
> > One more thing to pay attention to!
> > Need to occasionally communicate minimally with the server, otherwise it
> > may lose connection
> >
> 
> Let me see if I understand exactly what’s happening here.
> 
> A public server is running udp01. That is always available and can be
> contacted by anyone who initiates a connection.
> 
> When client A and B both connect to the server, your program connects them
> together and that established the path that all further UDP traffic between
> A and B will flow.
> 
> To ensure the path remains open, A and B need to contact the server once a
> minute or so…
> 
> Is that essentially correct?
> 
> Now for my next question. Is it possible to do the same for tcp?
> 
> John
> 
> >
> > --
> Sent from Gmail Mobile
------- End of Original Message -------



More information about the User mailing list