IPv6 Support

Jim Tcl has had ipv6 support ever since the WorkWare fork was merged back into mainline.

You can read more about it in the documentation at: socket

Basically it is a matter of specifying -ipv6 when creating the socket and giving an IPv6 address. For example:

set s [socket -ipv6 stream.server {[::]:2000}]

Note that IPv6 addresses are enclosed in square brackets. This is the same notation used for IPv6 URLs and makes it easy to keep the address:port syntax.

The address returned by recvfrom will be formatted appropriately, so it can be used directly by sendto.

Some simple IPv6 examples are included in the repository. For example: udp6.server

Note that on all hosts I have tried, listening on an IPv6 socket will also listen on the corresponding IPv4 socket. You can try this by running udp6.server and connecting with both udp6.client and udp.client

Steve Bennett (steveb@workware.net.au)

comments powered by Disqus