Network Protocol IPV6 knowledge points
Due to the rapid development and popularization of the Internet, the original IPV4 address can no longer meet the needs of network users, although NAT can alleviate IPV4 address depletion, however, NAT damages the openness, transparency, and end-to-end features of the network environment. Therefore, IPV6 address Protocol emerged. IPV6 uses a 128-bit address instead of a 32-bit IPV4 address, which can generate approximately 340 trillion million (3.4*1038) Available addresses. This number can meet the public IP address requirements. As an introduction to IPV6, this article mainly introduces IPV6 addresses and IPV6 packet formats.
IPV6 advantages
1. Larger address space: the 128-bit address space can satisfy everyone on the planet.
2. NAT not required: ensures end-to-end communication
3. No broadcast addresses: unicast, multicasting, and arbitrary Broadcasting
4. Support for mobility and security: helps ensure compliance with Mobile IP standards and Ipsec standards
5. Simpler packets improve the efficiency of routers
6. Interface ID: data link layer of the interface
New IPV6 features
1. Multiple addresses for each interface
2. local link address: When a route is changed, IGP uses the link-local address as the next hop address.
3. Automatic stateless configuration: an IPV6 device is assigned a unique link-local IPV6 address based on its own.
4. Independent or not independent from the provider's addressing
IPV6 address
1. IPV6 addresses are composed of 128 bits and are represented by 8 16-bit segments. Each 16-bit segment uses hexadecimal numbers to represent a group of 4 hexadecimal segments, separated by a colon (:)
2. Format: x indicates four hexadecimal digits. Example: 2035: 0001: 2BC5: 0000: 0000: 087C: 0000: 000A
3. IPV6 addresses include the prefix and local ID.
4. Prefix: Add a slash (/) next to the IPV6 address and a decimal number to identify the starting position of an IPV6 address. Generally, the prefix is 64-bit, example: 3ffe: 1994: 100: a:/64
5. Interface ID: The Interface ID is derived from the data link layer address of the interface, which is globally unique. The length is 64-bit. It is dynamically created based on the MAC address.
6. Special IPV6 addresses are listed in the following table:
IPV6 address |
Description |
:/0 |
Default route Equivalent to IPV4 0.0.0.0 |
:/128 |
Unspecified address Cannot be assigned to real Network Interfaces |
: 1/128 |
Local loopback address Equivalent to 127.0.0.1 of IPV4 |
FE80:/10 |
Local unicast link address Equivalent to the automatically configured Windows IP address 169.254.x.x |
FF00:/8 |
Multicast address |
Other addresses |
Global unicast address 001 (currently allocated): 2xxx:/4 or 3xxx:/4 Others are unallocated global unicast addresses |
Short IPV6 address rules:
1. In fields composed of four hexadecimal digits, the leading 0 can be omitted; for example, 09C0 = 9C0 0000 = 0
2. Each address can use a colon (: :) to indicate any number of consecutive 0 values. For example, ff02: 0000: 0000: 0000: 0000: 0000: 0000: 0005 = ff02: 5
Note: Only one pair of colons can appear in an address; otherwise, the address cannot be uniquely identified.
IPV6 address type
Address type |
Description |
Unicast |
One address identifies a single interface The group sent to the unicast address will be transmitted to the Address Identification interface. |
Multicast |
A multicast address identifies a group of interfaces on different devices. The group sent to the multicast address is transmitted to all interfaces identified by the address. Multicast addresses are not used as source addresses. |
Arbitrary playback |
One address is allocated to multiple interfaces. These interfaces represent different nodes. Send the group to the nearest interface (the first neighbor) in any multicast group. In other cases, the Group is determined based on the measurement value of the routing protocol. |
Global unicast address format: The network part provides the positioning of a device to a dedicated data link, and the host part provides the identification of the device on this data link. The 16-bit subnet ID field can provide 65536 (216) different subnets
Prefix for global routes (48) |
Subnet ID (16) |
Interface ID (64) |
Local Unicast address: The IP address that is limited to a single link. Uniqueness is only valid on the link where the address is located, and the same address may exist on another link. Therefore, the link where the address is located cannot be routed. The starting 10 bits of the local unicast link address is 1111111010 (FE80:/10)
Allocation of IPV6 unicast addresses:
Note: Each interface can have only one local link address.
Configuring only one global unicast address will also create a link local address (EUI-64) on the Interface)
You can configure multiple IPV6 addresses on the interface. IPV4 and IPV6 addresses can be configured simultaneously
The Ethernet Interface ID is an interface-based 48-bit MAC address with 16-Bit 0 XFFFE inserted in the middle.
Multicast address format
Multicast Prefix: 8 bits |
Tag: 4 digits |
Range: 4 digits |
ID: 112 |
Note: The first three bits are reserved as 0, and the first 4th bits are: 0-permanently recognized addresses; the first three bits are temporary addresses.
Scope: including: node local-0X1, link local-0X2, Region local-0X5, organization local-0X8, global-0XE, reserved-0XF 0X0
Group ID: The first 80 bits are set to 0 and only the last 32 bits are used.
Common accepted IPV6 multicast addresses: All of them belong to the permanent local range of The Link;
Address |
Multicast Group |
FF02: 1 |
All nodes |
FF02: 2 |
All Routers |
FF02: 5 |
OSPFv3 Router |
FF02: 6 |
Specify vro in OSPFv3 |
FF02: 9 |
RIPng Router |
FF02: |
VPN Router |
FF02: B |
Mobile Agent |
FF02: C |
DHCP server/relay proxy |
FF02: D |
All PIM Routers |
IPV6 Header Format
Note:
Version: 4 bits, 0110 indicates version 6
Traffic Type: 8-bit, similar to the TOS field in IPV4
Stream Tag: 20 bits. It is set to allow tags for specific business flows to provide finer granularity of service categories, when balancing service traffic through multiple paths, you can ensure that data packets of the same stream can always be forwarded to the same path. When initiating a data packet, add the appropriate flow tag field, the router can recognize a stream without having to look up the packet header. This field is currently ignored by the router.
Payload length: the length of the payload used to encapsulate data packets. The length of the IPV6 packet header is 40 bytes.
Next header: the header behind the IPV6 packet header, which is similar to the protocol field in the IPV4 packet.
Hop count limit: A tool similar to the TTL field in IPV4 to measure the maximum number of router hops that a data packet can span in the path to the destination.
Source Address and Destination Address: 128 characters in length
Optional: contains the expanded header and provides optional functions, such as segmentation, source route selection or authentication, destination option, TCP/IP protocol, etc. Whether the expanded header exists in the next packet Field
IPV6 Header |
Routing selection extension header |
Segmented extension header |
Authentication extension header |
Upper-layer protocol header |
Data |