close
Warning:
Can't synchronize with repository "(default)" (/common/SVN/crkit does not appear to be a Subversion repository.). Look in the Trac log for more information.
- Timestamp:
-
Jun 17, 2010, 2:56:15 AM (14 years ago)
- Author:
-
khanhle
- Comment:
-
--
Legend:
- Unmodified
- Added
- Removed
- Modified
-
v1
|
v1
|
|
| 1 | == Checksum Calculation (source : wikipedia) == |
| 2 | |
| 3 | For example, use Hex 45000030442240008006442e8c7c19acae241e2b (20 bytes IP header): |
| 4 | 4500 + 0030 + 4422 + 4000 + 8006 + 0000 + 8c7c + 19ac + ae24 + 1e2b = 2BBCF [[BR]] |
| 5 | 2 + BBCF = BBD1 = 1011101111010001, the 1'S of sum = 0100010000101110 = 442E |
| 6 | |
| 7 | To validate a header's checksum the same algorithm may be used - the checksum of the header with the checksum field filled in should be a word containing all zeros (value 0). |