Is connection-oriented, so it can only be used for point-to-point traffic.
TCP provides a reliable data flow service that uses the "positive acknowledgement of retransmission" technology to achieve reliable transmission
. TCP also uses a method called "sliding window" for traffic control, so-called window actually represents the ability to receive, with
to limit the sending speed.
UDP is for a non-connected communication protocol, the UDP data includes the destination port number and the source port number information, because the communication does not need to
the connection, therefore can implement the broadcast sends. The
UDP communication does not require the receiver to confirm, is not reliable transmission, may drop packet phenomenon, actual application requirements
in programmer programming verification. The
4, Application layer
Application tier is typically user-oriented. such as FTP, TELNET, DNS, SMTP, POP3. The
FTP (file transmision Protocol) is the files Transfer protocol, generally uploads the download with the FTP service, the data port
is 20H, the control port is 21H. The
Telnet Service is a user remote login service, using 23H port, using the plaintext transmission, the confidentiality is poor, simple and convenient. The
DNS (domain Name Service) is the domain name resolution service that provides conversions between domain names to IP addresses. The
SMTP (Simple Mail Transfer Protocol) is an easy mail Transfer protocol that controls the sending of letters, medium
.
POP3 (Post Office Protocol 3) is the 3rd version of the Post Office protocol that is used to receive messages.
Data format:
Data frame: Frame header +ip packet + frame tail (frame header includes source and destination host MAC address and type, end of frame is check word)
IP packet: IP header +tcp Data information (IP headers include source and destination host IP address, type, lifetime, etc.)
TCP Data information: TCP headers + actual data (TCP header includes source and destination host port number, shun sequence number, confirmation number, school
Check word, etc.)
The physical layer specifies the mechanical, electrical, functional, and process characteristics that activate, maintain, and close communication endpoints. This layer provides a physical medium for the upper level protocol to transmit data.
In this layer, the unit of data is called the bit (bit).
Typical canonical representatives belonging to the physical layer definition include: Eia/tia RS-232, Eia/tia RS-449, v.35, RJ-45, etc.
The data link layer provides reliable transmission on unreliable physical media. The functions of this layer include: Physical address addressing, data framing, flow control, data error checking, re-sending, etc.
In this layer, the units of the data are called frames.
The Data Link layer protocol includes: SDLC, HDLC, PPP, STP, Frame Relay, and so on.
The network layer is responsible for routing data packets between subnets. Network layer can also realize congestion control, Internet interconnection and other functions.
At this level, the unit of data is called a packet (packet).
Network layer protocol representatives include: IP, IPX, RIP, OSPF, and so on.
The transport layer is the first end-to-end, that is, the host-to-host hierarchy. The transport layer is responsible for segmenting the upper data and providing an end-to-end, reliable, or unreliable transmission. In addition, the transport layer also handles end-to-end error control and flow control issues.
In this layer, the unit of data is called the Data segment (segment).
The Transport Layer protocol includes: TCP, UDP, SPX, and so on.
The session layer manages the session process between hosts, which is responsible for establishing, managing, and terminating sessions between processes. The session layer also uses the insertion of checkpoints in the data to synchronize data.
The presentation layer transforms the upper data or information to ensure that one host application layer information can be understood by another host's application. The data transformation of the presentation layer includes data encryption, compression, format conversion, and so on.
The application layer provides an interface for operating system or network applications to access network services.
Application-layer protocols include: Telnet, FTP, HTTP, SNMP, etc.