Ever tried to convert IPv4 code into IPv6 plus IPv4 supported code? Probably you might have done the following:
1. Figured out what projects using IPv4 related calls(APIs)
2. In each project you might have scanned all network APIs and data structures whether it got hard-coded with IPv4 or not?
3. Then you might have checked what is the equivalent call/data members available to support both IPv6 and IPv4 then you would have replaced your code with those.
Stop going all these way!
Microsoft provides tool called as Checkv4.exe utility to do the same job.
What this tool will do?
All you need to do is just give your file/folder as the input to this tool, this tool will recommand you what you need to change to support IPv6 + IPv4!
Where can i get this?
It is coming along with latest SDK(Vista SDK). This SDK is available thru MSDN subscription.
To modify IPv4 applications to support IPv6 (from MS recommandation)
# Fix structures and declarations to enable IPv6 and IPv4 compatibility.
# Modify function calls to take advantage of IPv6-enabled functions, such as the getaddrinfo and getnameinfo functions.
# Review source code for the use of hard-coded IPv4 addresses such as the loopback address, or the use of other literal strings.
# Perform a thorough review of the user interface, including informational dialog boxes. Give thought to whether it is appropriate for IPv6-enabled applications to specify or provide IP-address based information.
# Determine whether your application relies on underlying protocols, such as RPC, and make appropriate programmatic changes to handle IPv6 addresses.
# Use the compile-time flag IPV6STRICT when compiling applications on Windows XP and later. This flag results in incompatible code failing to compile, as follows:
Windows Sockets 1.x applications with incompatible code fail to compile and return the error message "WINSOCK2 Required."
Windows Sockets 2.x applications with incompatible code cause a compile time error for each instance of incompatible code. An error message is generated in the following format:
[file name] ([line number]) : [error message] '[symbol]_IPV6INCOMPATIBLE'
For example:
sample.c(8) : error C2065: 'gethostbyaddr_IPV6INCOMPATIBLE' : undeclared identifier
1. Figured out what projects using IPv4 related calls(APIs)
2. In each project you might have scanned all network APIs and data structures whether it got hard-coded with IPv4 or not?
3. Then you might have checked what is the equivalent call/data members available to support both IPv6 and IPv4 then you would have replaced your code with those.
Stop going all these way!
Microsoft provides tool called as Checkv4.exe utility to do the same job.
What this tool will do?
All you need to do is just give your file/folder as the input to this tool, this tool will recommand you what you need to change to support IPv6 + IPv4!
Where can i get this?
It is coming along with latest SDK(Vista SDK). This SDK is available thru MSDN subscription.
To modify IPv4 applications to support IPv6 (from MS recommandation)
# Fix structures and declarations to enable IPv6 and IPv4 compatibility.
# Modify function calls to take advantage of IPv6-enabled functions, such as the getaddrinfo and getnameinfo functions.
# Review source code for the use of hard-coded IPv4 addresses such as the loopback address, or the use of other literal strings.
# Perform a thorough review of the user interface, including informational dialog boxes. Give thought to whether it is appropriate for IPv6-enabled applications to specify or provide IP-address based information.
# Determine whether your application relies on underlying protocols, such as RPC, and make appropriate programmatic changes to handle IPv6 addresses.
# Use the compile-time flag IPV6STRICT when compiling applications on Windows XP and later. This flag results in incompatible code failing to compile, as follows:
Windows Sockets 1.x applications with incompatible code fail to compile and return the error message "WINSOCK2 Required."
Windows Sockets 2.x applications with incompatible code cause a compile time error for each instance of incompatible code. An error message is generated in the following format:
[file name] ([line number]) : [error message] '[symbol]_IPV6INCOMPATIBLE'
For example:
sample.c(8) : error C2065: 'gethostbyaddr_IPV6INCOMPATIBLE' : undeclared identifier