Home > Common Problem > What are the number of digits in ipv4 and ipv6 addresses?

What are the number of digits in ipv4 and ipv6 addresses?

青灯夜游
Release: 2022-11-23 10:56:50
Original
29787 people have browsed it

The IPv4 address is 32 bits, expressed in dotted decimal notation, divided into eight bits, that is, four decimal numbers from 0 to 255; the IPv6 address is 128 bits, generally expressed in dotted hexadecimal notation Indicates that it is divided into eight bits, that is, sixteen hexadecimal numbers from 0x00 to 0xff. The IPv6 address length is 128 bits, which is four times the length of the IPv4 address; an IPv6 IP address consists of 8 address sections, each section contains 16 address bits, and the total length is 16x8=128 bits.

What are the number of digits in ipv4 and ipv6 addresses?

The operating environment of this tutorial: Windows 7 system, Dell G3 computer.

The address of ipv4 is 32 bits, while the address of ipv6 is 128 bits.

What is ipv4

Internet Protocol version 4 (English: Internet Protocol version 4, IPv4), also known as Internet Communication Protocol Version 4 is the fourth revision in the development process of the Internet Protocol and the first widely deployed version of the protocol. IPv4 is the core of the Internet and the most widely used version of the Internet Protocol. Its successor version is IPv6. Until 2011, when the IANA IPv4 addresses were completely exhausted, IPv6 was still in the early stages of deployment.

The IPv4 address is 32 bits, expressed in dotted decimal notation, divided into eight bits, that is, four decimal numbers from 0 to 255, which is very common.

IPv4 uses 32-bit (4-byte) addresses, so there are only 4,294,967,296 (2) addresses in the address space. However, some addresses are reserved for special purposes, such as private networks (about 18 million addresses) and multicast addresses (about 270 million addresses), which reduces the number of addresses that can be routed on the Internet. As addresses continue to be allocated to end users, the problem of IPv4 address exhaustion is also arising. Address structure reconstruction based on classified networks, classless inter-domain routing, and network address translation significantly reduces the rate of address exhaustion. But on February 3, 2011, after the last five address blocks had been allocated to the five regional Internet registries, IANA's main address pool was exhausted.

These limitations have spurred the deployment of IPv6, which is still in its early stages of development and is the only long-term solution.

Address Format

An IPv4 address can be written in any form that represents a 32-bit integer value, but to facilitate human reading and analysis, it is usually written in dotted decimal notation form, that is, the four bytes are written separately in decimal notation, separated by dots.

The following table shows several different formats:

##Each byte is converted to octal individuallyHex0xC00002EB Divide the dots into ten Hexadecimal connected togetherDecimal3221226219 A 32-bit integer written in decimal octal030000001353A 32-bit integer written in octal

In addition, in dotted format, each byte can be expressed in any base. For example, 192.0x00.0002.235 is a legal (but not commonly used) representation.

What is ipv6

IPv6 is the abbreviation of "Internet Protocol Version 6" in English and is an Internet engineering task The next-generation IP protocol designed by the IETF to replace IPv4 has a number of addresses that it claims can provide an address for every grain of sand in the world.

The biggest problem of IPv4 is the insufficient network address resources, which seriously restricts the application and development of the Internet. The use of IPv6 can not only solve the problem of the number of network address resources, but also solve the obstacles for multiple access devices to connect to the Internet.

IPv6 is designed to replace IPv4. However, IPv4 has still occupied a dominant position in Internet traffic for a long time, and the use of IPv6 has grown slowly. In April 2022, the percentage of users using Google services through IPv6 exceeded 40% for the first time.

The IPv6 address is 128 bits, which is 4 times the length of the IPv4 address. It is generally expressed in dotted hexadecimal, divided into eight bits, that is, sixteen hexadecimal numbers from 0x00 to 0xff. .

An IPv6 IP address consists of 8 address sections, each section contains 16 address bits, and the total length is 16x8=128 bits.

What are the number of digits in ipv4 and ipv6 addresses?

So the IPv4 dotted decimal format is no longer applicable and is expressed in hexadecimal.

The difference between IPv4 and IPv6 protocols

1. The difference between protocol addresses

1) , Address length

IPv4 protocol has a 32-bit (4-byte) address length; IPv6 protocol has a 128-bit (16-byte) address length

What are the number of digits in ipv4 and ipv6 addresses?

2 ), address representation method

IPv4 address is a binary number expressed as a decimal. IPv6 addresses are binary numbers represented in hexadecimal notation.

3) Address configuration

The IPv4 protocol address can be configured manually or through DHCP.

The IPv4 protocol requires the use of Internet Control Message Protocol version 6 (ICMPv6) or DHCPv6's Stateless Address Autoconfiguration (SLAAC).

2. Differences in data packets

1) Packet size

IPv4 protocol data packets require 576 bytes, fragmentation is optional . The data packet of the IPv6 protocol requires 1280 bytes and will not be fragmented

2), the header

The length of the IPv4 protocol header is 20 bytes and does not identify data used for QoS processing Packet stream, including checksum, containing options field of up to 40 bytes.

The IPv6 protocol header is 40 bytes in length and contains the Flow Label field of the packet flow specified by QoS processing, excluding checksum; the IPv6 protocol has no field, but the IPv6 extension header is available.

3) Packet fragmentation

IPv4 protocol packet fragmentation will be completed by the forwarding router and the sending host. Packet fragmentation of the IPv6 protocol is only done by the sending host.

What are the number of digits in ipv4 and ipv6 addresses?

3. DNS record

IPv4 protocol address (A) record, mapping host name; pointer (PTR) record, IN-ADDR.ARPA DNS domain.

IPv6 protocol address (AAAA) record, mapped host name; pointer (PTR) record, IP6.ARPA DNS domain

4, IPSec support

IPSec support for the IPv4 protocol is only optional. The IPv4 protocol has built-in IPSec support.

5. Address Resolution Protocol

IPv4 Protocol: Address Resolution Protocol (ARP) can be used to map IPv4 addresses to MAC addresses.

IPv6 protocol: Address Resolution Protocol (ARP) is replaced by the functionality of Neighbor Discovery Protocol (NDP).

6. Authentication and encryption

Pv6 provides authentication and encryption, but IPv4 does not.

For more related knowledge, please visit the FAQ column!

Base conversion table
Format
Value
Conversion from dotted decimal
Dotted decimal
192.0.2.235
Not applicable
##Dotted Hexadecimal
0xC0.0x00.0x02.0xEB
Each byte is converted to hexadecimal individually
Dotted Octal
0300.0000.0002.0353

The above is the detailed content of What are the number of digits in ipv4 and ipv6 addresses?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template