Note that IPv6 addresses are 128 bits, 16 bytes, 4 times longer than IPv4 (Internet Protocol Version 4) addresses. You’d think 64 bits, allowing 18,744,073,709,551,616 addresses, or 30,77,457 addresses per person would have sufficed. However, to avoid another transition for a very long time, they went for 128 bits. This will allow simpler routing, since bands can be assigned for various regions that won’t soon fill up, and require juggling to shift slots from other regions.
The Java class for dealing with these is called java.net.Inet6Address, though java.net.InetAddress will work too. The new headers, surprisingly, have fewer fields than before, and are fixed length 40 bytes to streamline processing. New features include:
|IPv6 Packet Header|
|Field||Size in bits||Purpose|
|version||4||6 for IP version 64. This allows IPv4 and IPv6 packets to be mixed.|
|payload length||16||total size of data payload measured in 8-bit chunks (aka bytes or octets). The means the maximum size of a packet including data is 64K. This means the payload of data is at most 65,496 bytes.|
|hop limit||8||how many more hops this packet has to live before being discarded as lost or hopelessly late. On each leg of this packet’s journey, this field gets decremented by 1.|
|source address||128||Who sent the packet. When it finally arrives at its destination the receiver will know who it was from.|
|destination address||128||Where the packet is going. On each leg of its journey the routing computer uses this to get the packet a little closer to its final destination.|
|other stuff||36||Miscellaneous fields.|
Everything is in big endian byte order.
Java 1.4.1+ handles the new IPs with java.net.InetAddress and java.net.Inet6Address.
available on the web at:
optional Replicator mirror
Please email your feedback for publication, letters to the editor, errors, omissions, typos, formatting errors, ambiguities, unclear wording, broken/redirected link reports, suggestions to improve this page or comments to Roedy Green : . If you want your message, your name or email kept confidential, not considered for public posting, please explicitly specify that. Unless you state otherwise, I will treat your message as a letter to the editor that I may or may not publish in the feedback section. After that, it will be too late to retract it. If you disagree with something I said, especially when sending an ad-hominem attack, a rant composed mainly of obscenities or a death threat, please quote the offending passage and cite the web page where you found it, tell me why you think it is wrong, and, if possible, provide some supporting evidence. I can’t very well fix erroneous or ambiguous text if I can’t find it.
Your face IP:[126.96.36.199]
|Feedback||You are visitor number 16,064.|