The IP address consists of two parts, namely the network address and the host address; the network address indicates which network on the Internet it belongs to, and the host address indicates which host in the network it belongs to; the two are master and slave. relation.
#The operating environment of this article: Windows 7 system, Dell G3 computer.
IP address consists of four segments, each field is one byte, 8 bits, and the maximum value is 255.
IP address consists of two parts, namely the network address and the host address. The network address indicates which network on the Internet it belongs to, and the host address indicates which host in the network it belongs to. The two are in a master-slave relationship.
The four major types of IP addresses identify a certain host on the network. The IPv4 address length is 32 bits and 4 bytes in total, but in practice we use dotted decimal notation.
IP addresses are divided according to the network number and host number, and are divided into three categories: A, B, C and special addresses D and E. Leave all 0s and 1s unused.
Class A: (1.0.0.0-126.0.0.0) (Default subnet mask: 255.0.0.0 or 0xFF000000) The first byte is the network number, and the last three characters Section is the host number. The beginning of this type of IP address is "0", so the network number of the address ranges from 1 to 126. Generally used in large networks.
Class B: (128.0.0.0-191.255.0.0) (Default subnet mask: 255.255.0.0 or 0xFFFF0000) The first two bytes are the network number, and the last two characters Section is the host number. The first part of this type of IP address is "10", so the network number of the address ranges from 128 to 191. Generally used for medium-sized networks.
Class C: (192.0.0.0-223.255.255.0) (Subnet mask: 255.255.255.0 or 0xFFFFFF00) The first three bytes are the network number, and the last byte is host number. The beginning of this type of IP address is "110", so the network number of the address ranges from 192 to 223. Generally used for small networks.
Class D: It is a multicast address. The beginning of this type of IP address is "1110", so the network number of the address ranges from 224 to 239. Generally used for multicast users[1].
Class E: is a reserved address. The beginning of this type of IP address is "1111", so the network number of the address ranges from 240 to 255.
In the three main types of IP addresses, three areas are reserved as private addresses. The address range is as follows:
Class A Address: 10.0.0.0~10.255.255.255
Class B address: 172.16.0.0~172.31.255.255
Class C address: 192.168. 0.0~192.168.255.255
Return address: 127.0.0.1. Also the local machine address, equivalent to localhost or local machine IP. Generally used for testing. For example: ping 127.0.0.1 to test whether the local TCP/IP is normal.
Related video recommendations: PHP video tutorial
The above is the detailed content of How to classify IP addresses. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 Chinese version
Chinese version, very easy to use

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.

SublimeText3 English version
Recommended: Win version, supports code prompts!

mPDF
mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

SecLists
SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.
