CheckSum

1、What is Checksum?

A check sum is basically a value that is computed from data packet to check its integrity(完整性). Through integrity, we mean a check on whether the data received is error free or not(数据是否正确). This is because while traveling on network a data packet can become corrupt and there has to be a way at the receiving end to know that data is corrupted or not(在接收端识别出数据是否有错). This is the reason the checksum field is added to the header. At the source side, the checksum is calculated and set in header as a field. At the destination side, the checksum is again calculated and crosschecked with the existing checksum value in header to see if the data packet is OK or not(在目的端或者接收端,重新计算 checksum/校验和,并和 数据头/packet header 里的 (existing checksum value)/已存校验和 比较/crosscheck。) .

REFER: How to Calculate IP Header Checksum (With an Example)

原文地址:https://www.cnblogs.com/xuanyuanchen/p/6000935.html