#transport layer loopbackipv4 works but parse doesn't.

1 messages · Page 1 of 1 (latest)

sand flower
#

I'm trying to setup a connection via the transport layer. I had everything working fine using the loopback endpoint but when I changed it to use my actual public IP via the parse function it kept failing to establish a connection. Any ideas?

#

interesting, i just tested with my local IP address and it worked so i guess I just cant connect to my own computers public ip for some reason? Hopefully a computer on another network wont have any issue with it

#

using my public IPv6 fixed the issue!

sand flower
#

Update: when I tried making a webgl build it was back to the same not connecting thing even with the ipv6 (once again I verified it works with loopback and i am using wss)

quartz vigil
#

Any reason you are using the low level Transport instead of higher levels of Netcode?

sand flower
#

I was originally using pure sockets and my own websocket headers but I'm in the process of converting it actually.

#

The functionality has had its own issues ofc but its working fine for right now

craggy river
#

Just trying to clarify, you have a server running on your LAN and you're attempting to connect to it from within the LAN using your public IP address? If you're behind a NATing router, then it not working is expected. NAT prevents that kind of self-connection using the public IP address. (And I'm guessing it works with IPv6 because the router doesn't do NAT on IPv6.)

sand flower
#

I can get you code snippets when I get home from work but the setup is basically the same as the sample from the documentation but with the parsed endpoint and the addition of the WithSecureClientParameters("mydomain.com");
And
WithSecureServerParameters(cert,key);

craggy river
#

Can you connect your WebGL build over IPv6 on localhost? Or does it fail only for remote connections?

Also if you're following the documentation to establish a secure connection, then you ended up with a self-signed certificate. Browsers by default will not accept those since they require the server's certificate to be signed by an official CA. And also on WebGL we connect directly to the domain provided to WithSecureClientParameters (since on browsers the URL we connect to must match the domain in the certificate). So you need to ensure your local DNS resolver will resolve "mydomain.com" to your IP address.

sand flower