Thanks very much for the response. Why five packets? A few extra to insure delivery?
On Thu, Jan 20, 2011 at 7:43 PM, Philip Bennefall <[email protected]>wrote: > Hello there, > > In my implementation I simply open a UDP socket directly, send about 5 > packets with a small interval between each, and close the socket again. > Then, ENet kicks in and attempts a connection. The ENet socket wrapper > functions are more convenient, but obviously the result will be exactly the > same so it just depends on your taste. > > > Kind regards, > > Philip Bennefall > ----- Original Message ----- > *From:* Jay Sprenkle <[email protected]> > *To:* Discussion of the ENet library <[email protected]> > *Sent:* Friday, January 21, 2011 2:36 AM > *Subject:* [ENet-discuss] ENet and NAT hole punching > > Good evening, > > I'm interested in making my ENet powered application able to do NAT hole > punching. > > After looking through the NAT hole punching RFC it looks fairly simple > (section 2.3 > here<http://pdos.csail.mit.edu/%7Ebaford/nat/draft-ford-natp2p-00.txt> > ). > What is needed is a way to send a single packet to a specific address and > port number. > The content of the packet isn't important since it will be discarded > anyway. It's just used to get the NAT to remember the address. > > If I read the source correctly I could simply open a connection and let it > fail. > Is there any way to send this packet without going through all the > overhead? > > Perhaps just call enet_socket_send() directly? > >
_______________________________________________ ENet-discuss mailing list [email protected] http://lists.cubik.org/mailman/listinfo/enet-discuss
