Introduction
User Datagram Protocol is a protocol that defines the computer communication used to provide Packet Exchange in the interconnected network environment. By default, this Protocol considers the network protocol (IP) as its underlying protocol. This Protocol provides the simplest Protocol mechanism for sending information to another user program. This Protocol is operation-oriented and does not provide commit and copy protection. If the application requires reliable data transmission, the transmission control protocol (TCP) should be used ). The datagram format is as follows:
User Data Header Format
Domain
The source port is an optional domain. when it makes sense, it refers to the port of the sending process. This assumes that the returned information should be sent to somewhere else without any other information. If you do not use it, enter 0 in this field. The destination port has a specific destination network address. The length refers to the octal representation of the User Datagram length. (This indicates that the minimum datagram length is 8 .) The verification code has 16 bits, which is obtained by reverse and reverse operations on the IP address header, UDP header, and the number of information headers in the data.
In terms of concept, the header is before the UDP header information. It includes the source address, Destination Address, protocol used, and UDP length. This information cannot be mistakenly received. This verification process is consistent with the process used in TCP.
If the calculated verification code is zero, it will be completely sent by zero. The zero-sum check value means that the sender does not generate a check code.
User Interface
The user interface should allow the creation of a new receiving port. The receiving operations on the receiving port include: an octal number indicating the source port and source address should be returned, allowing datagram transmission and specifying data, source and target ports and destination addresses.
IP layer interface
The UDP module must be able to determine the network address of the source and target, and be able to know the protocol used from the header. One possible interface is to return the entire datagram, including the header returned by the receive operation. This interface should also allow UDP to send a complete packet header to the IP address for transmission. The IP address is used to determine the consistency and calculate the verification code.
Protocol Application
The main purpose of this Protocol is the Internet Name Server and small file transfer protocol.
Protocol No.
When an IP address is used, its Protocol Number is 17 (21 in octal ).