Network protocol basis for software testing

Network protocol basis for software testing

Foreword
I will continue to update on this account, software testing articles, including network part, front-end code part, database part, software testing part

Internet protocol

osi 7 layer protocol
tcp/ip 5 layer protocol
network protocol exists for communication between the two according to a certain protocol

Common physical equipment running on each layer

Transport layer: Layer 4 switch,
Layer 4 router Network layer: Router, Layer 3 switch
Data link layer: Bridge, Ethernet switch, network card
Physical layer: Repeater, hub, twisted pair

Transport layer TCP/UDP protocol

TCP: Transmission Control Protocol, which defines the format of data and confirmation information exchanged for reliable transmission between two computers. The biggest feature of TCP is that it provides a connection-oriented, reliable byte stream service.
UDP: User Datagram The protocol is a simple datagram-oriented transport layer protocol. UDP provides a non-connection-oriented and unreliable data stream transmission. UDP does not provide reliability.

osi five-layer protocol data transmission process

Application layer: Data
Transport layer: TCP header/UDP header+data
Network layer: IP header+TCP header/UDP header+data
Data link layer: Frame header+IP header+TCP header/UDP header+Data
Physical layer: Convert to Bit rate

Now let's explain the 5 layer protocol layer by layer
First: the physical layer

If you want to communicate between computers, you must network
function: mainly based on the characteristics of electrical appliances to send high and low voltage (electrical signal) high voltage corresponds to number 1, low voltage corresponds to number 0

Second: data link layer

Simple electrical signals 0 and 1 have no meaning. You must specify how many bits are in one group, and what does each group mean.
Function: defines the grouping method of electrical signals

Third: Network layer

Introduce a new set of addresses to distinguish between different broadcast domains/subnets, this set of addresses is the network address

Fourth: Transport layer

The ip at the network layer helps us in the molecular network, and the mac at the Ethernet layer helps us find the host. Then we find a specific host through ip and mac. How to identify the application on this host is the port, and the port is the application The number associated with the program and the network card
Function: establish port-to-port communication

Fifth: Application layer

The Internet is open, everyone can develop their own applications. There are many kinds of data, and the organization format of the data must be specified.
Function: specify the data format of the application

Guess you like

Origin blog.csdn.net/HONGTester/article/details/107084692