Author Topic: Testing IPv6 on iOS  (Read 11143 times)

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #15 on: July 29, 2016, 09:29:43 PM »
Also one more thing... the TNManager.Connect(string) function currently isn't fit for IPv6, which is what the menu's GUI uses. Either use TNManager.Connect(string, int), or update the Connect(string) function with this:
  1.         static public void Connect (string address)
  2.         {
  3.                 string[] split = address.Split(new char[] { ':' });
  4.                 int port = 5127;
  5.                 if (split.Length == 2 && int.TryParse(split[1], out port)) Connect(split[0], port);
  6.                 else Connect(address, port);
  7.         }

P.S. Informative explanation of the IPv6 address format: http://computernetworkingnotes.com/ipv6-features-concepts-and-configurations/ipv6-address-types-and-formats.html
« Last Edit: July 29, 2016, 10:54:27 PM by ArenMook »

voncarp

  • Jr. Member
  • **
  • Thank You
  • -Given: 13
  • -Receive: 2
  • Posts: 91
    • View Profile
Re: Testing IPv6 on iOS
« Reply #16 on: July 30, 2016, 02:10:39 AM »
Using http://test-ipv6.com/ on the server yields:



And trying to connect again



I left the TNServer.exe and port open for this test. Are you able to connect from your side?

2002:6c3d:582b::6c3d:582b

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #17 on: July 30, 2016, 02:43:20 AM »
Update to the latest TNet (3.0.3), I integrated all the tweaks in there.

Nope, I can't connect to 2002:6c3d:582b::6c3d:582b.

You can check it yourself: http://www.ipv6scanner.com/cgi-bin/main.py
Or: http://www.subnetonline.com/pages/ipv6-network-tools/online-ipv6-port-scanner.php

The report says the port is filtered on your server's side: "The port is blocked by firewall or other network obstacle".
« Last Edit: July 30, 2016, 05:41:55 AM by ArenMook »

voncarp

  • Jr. Member
  • **
  • Thank You
  • -Given: 13
  • -Receive: 2
  • Posts: 91
    • View Profile
Re: Testing IPv6 on iOS
« Reply #18 on: July 30, 2016, 05:46:18 AM »
Interesting.  So opening a port for IPv6 is different than IPv4?

Using a different server and IPs for port 5127

2002:a1ca:90f2::a1ca:90f2
161.202.144.242

The IPv4 shows open.
The IPv6 shows closed.

To check this. 

http://www.blueseq.com/ipv6-portscanner.php?addr=161.202.144.242&port=5127&agree=0
http://www.subnetonline.com/pages/ipv6-network-tools/online-ipv6-port-scanner.php

Ran out of tries with http://www.ipv6scanner.com/ You only get 3 in one day  :-\

The original server and IP's display the same result. Open on IPv4 and closed on IPv6.

Edit:

I'll have to investigate more on how to get the IPv6 port open. Feel free to share any thoughts :)
« Last Edit: July 30, 2016, 05:51:31 AM by voncarp »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #19 on: July 30, 2016, 05:48:27 AM »
Random footnote... In order to be able to host IPv6 servers properly I had to actually enable the IPv6 option on my router. It was off by default, and chrome couldn't even connect to IPv6 sites (although IE could, go figure). Once I enabled IPv6 native support on my router, a lot of things changed. The default LAN address is now always IPv6. Going to some of the IP checking sites like http://icanhazip.com/ shows my IPv6 address instead of the IPv4 one. The number of visible interfaces also grew dramatically (7!).

When I ran "ipconfig" in the command line before, I saw IPv6 address only under the "tunnel" section. Now I see it as my main address. My tunnel IP started with 2001. Actual IP begins with 2607.

I see both IPv6 address and a "temporary IPv6 address", whatever that means. Either one works for accepting incoming connections, but I made TNet default to the first one (which is the real one, not the temporary one).

One thing I noticed that in IPv6 LAN address matches the IPv6's WAN address. The LAN one begins with fe80:: (means local LAN), but the remaining text matches what's in the WAN address. Which makes sense -- the WAN address is just the address of your network, followed by the address of your computer.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #20 on: July 30, 2016, 05:51:22 AM »
Ran out of tries with http://www.ipv6scanner.com/cgi-bin/main.py. You only get 3 in one day  :-\
Use http://www.subnetonline.com/pages/ipv6-network-tools/online-ipv6-port-scanner.php instead, it's not limited.

I'm guessing you are in the same situation that I was -- your IPv6 address is for outbound connections only. It's a tunnel address, not a real IPv6 address.

Check with ipconfig.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #21 on: July 30, 2016, 05:54:47 AM »
One more thing... the http://test-ipv6.com/ test for me was 7/10 before I changed to IPv6 on my router.

Now it's 10/10.

voncarp

  • Jr. Member
  • **
  • Thank You
  • -Given: 13
  • -Receive: 2
  • Posts: 91
    • View Profile
Re: Testing IPv6 on iOS
« Reply #22 on: July 30, 2016, 06:34:40 AM »
Hmm. The thing is, I am not using a router.  I am using several different dedicated servers with Windows Server 2008 and 2012.  My test servers are from gameservers.com.  The TNServer.exe I uploaded there. I felt my location, Hawaii; was not favorable for connections.

This is from the external dedicated server on gameservers.com



And I have been swapping in and out of TNServer.exe IPv6 and IPv4 for testing. ipconfig



Maybe on the dedicated server, I am missing a step to get this to work.  5127 shows open on IPv4, just not IPv6.

I'll have to continue research in the morning. Very much appreciate the support  ;D


ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #23 on: July 30, 2016, 07:01:20 AM »
Yup, both IPs show up as "tunnel" on ipconfig, and your server is "6to4" suggests that as well. So that's your issue right there. It's not a real IPv6 connection. It's just a tunnel.

voncarp

  • Jr. Member
  • **
  • Thank You
  • -Given: 13
  • -Receive: 2
  • Posts: 91
    • View Profile
Re: Testing IPv6 on iOS
« Reply #24 on: July 30, 2016, 03:42:21 PM »
I am still unable to connect. But, I think the setup is right:

Verified the port is open for IPv6





And the TNServer.exe



I ran this from an iPhone with the useIPv6 bool = true. I ran it from the iPhone because I am certain that is a NAT 64 network. When useIPv6 bool = false it shows IPv4 in LAN and WAN. Either way it was unable to connect. I updated to the latest TNet3 and used the latest TNServer.zip



Would you be able to try to connect to that when you are back online?

2002:a1ca:90f2::a1ca:90f2

Edit:

The ports didn't seem like they were open last night.  After some modification and according to those two sites they are open now.

cmifwdll

  • Global Moderator
  • Sr. Member
  • *****
  • Thank You
  • -Given: 0
  • -Receive: 149
  • Posts: 285
  • TNet Alchemist
    • View Profile
Re: Testing IPv6 on iOS
« Reply #25 on: July 30, 2016, 09:29:08 PM »
I can connect but it seems the connection is severed immediately.

I placed a Debug.Log in TcpProtocol::OnConnect and checked wireshark. The handshake completes w/ the ack packet, then the TNet connection takes place:
0000   0c 00 00 00 03 0c 00 00 00 05 47 75 65 73 74 00  ..........Guest.
Which your server responds to with:
0000   05 00 00 00 09 00 00 00 00                       .........

Then severs the connection with FIN/ACK.
This could be because of a version mismatch. My Player.version is 12. Yours is probably different, so when you receive my Packet.RequestID the server closes the connection.
Packet ID 9 is RequestSetPlayerLimit for me though, dunno what's up with that.

Maybe the TNet console will provide more information.

edit: if you do post the contents of the console, please redact my IP :P
« Last Edit: July 31, 2016, 02:05:23 AM by cmifwdll »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Testing IPv6 on iOS
« Reply #26 on: July 31, 2016, 09:48:10 AM »
Judging by the fact that your TNServer isn't listing WAN/LAN and instead shows "Primary" next to IPs, you are not running the latest version. I did say you need to update to 3.0.3. This includes the server executable.

P.S. Yes, I am able to connect to your server now.