How to Calculate IP Checksum
Data is sent through IP networks such as the Internet in sets of information called packets. When you send an email, for example, the email is not transmitted as a single document. Instead, the email is divided into packets. The packets are sent individually and the email is reassembled for its recipient when all the packets have arrived at his computer. To reassemble the email correctly, all the packets that compose it must be complete and unaltered when they are received. To ensure that the packets are unaltered, a bit of code called a checksum is created for each packet. Any change to a packet will automatically change its checksum. Therefore, if the checksum of the packet when it is sent matches the checksum of the packet when it is received, it is confirmed to be unaltered. Calculating and confirming IP checksums is an automated process. However, if you want to calculate the IP checksum of a packet you have captured, you can do so using an open source packet analyzer such as Wireshark.
- Difficulty:
- Moderately Easy
Instructions
-
-
1
Open the Wireshark utility.
-
2
Click the "File" link in the Wireshark menu bar then click the "Open" icon in the drop-down menu. This opens the Wireshark Open Capture File dialog window.
-
3
Locate the file containing the packet for which you want to know the checksum and select it in the dialog window. The .cap format is a common format for captured packet data. Click the "Open" button in the dialog window to open the capture file and display the information it contains in the main Wireshark window.
-
4
Click to select the individual packet for which you want to know the IP checksum in the Packet List pane of the main Wireshark window.
-
5
Scroll to the Internet Protocol data set in the Packet Details pane of the main Wireshark window. The checksum calculated for the packet you have selected is displayed in hexadecimal format in the "Header checksum" item.
-
1