IPv4 to IPv6

Noah Aas 985 Reputation points
2024-10-27T15:54:22.4933333+00:00

Hello,

https://en.wikipedia.org/wiki/IPv6

Comparison of change between IP4 and 6? E.g. for the TCP listener? Are there any examples?

  • IPv4: ? 83.235.77.69
  • IPv6: ? Not detected

How does the connection between client and server take place?

Sample, until now my app works with IPv4. Customer tell me change to IPv6 What must I to do?

Developer technologies | C#
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Anonymous
    2024-10-28T06:56:58.2466667+00:00

    Hi @Noah Aas , Welcome to Microsoft Q&A,

    • IPv4: 32-bit address format, typically written as four decimal numbers separated by dots (e.g., 83.235.77.69). - IPv6: 128-bit address format, written as eight groups of four hexadecimal numbers separated by colons (e.g., 2001:0db8:85a3:0000:0000:8a2e:0370:7334).
    • IPv4 typically relies on NAT to manage the IP address shortage.
    • IPv6 has an abundant address space and typically eliminates the need for NAT, simplifying end-to-end connectivity
    • IPv4 is limited to approximately 4.3 billion addresses, which is insufficient for modern needs.
    • IPv6 addresses this limitation by providing a huge address space (approximately 340 exabytes).

    If you need to support both protocols, make sure to configure Socket in dual stack mode by setting SocketOptionName.IPv6Only to false. This allows both IPv4 and IPv6 clients to connect.

    For TCP examples you can check out these two days of information I found: C# server that supports IPv6 and IPv4 on the same port and Using ipv6 address to connect to a server using HttpClient

    Best Regards,

    Jiale


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". 

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.