Internet Checksum Residue Check

Verify an explicit Internet-checksum word list including its checksum against all-one folded residue; no packet-field or protocol coverage assumptions.

Description

Verify an explicit Internet-checksum word list including its checksum against all-one folded residue; no packet-field or protocol coverage assumptions.

An Internet-checksum residue uses end-around-carry addition of 16-bit words. A fully supplied valid sum, including its checksum, has an all-ones residue under this test.

When to use this tool

Verify an explicit Internet-checksum word list including its checksum against all-one folded residue; no packet-field or protocol coverage assumptions.

  • Prepare the supplied words fields for this operation.
  • Compare the complete example with the representation used by your own input before carrying the result into another step.

How to use the tool and how it works

  1. Enter words. Use the exact text syntax, units and index conventions explained below.
  2. Run the tool. If input validation fails, correct the supplied fields before interpreting any result.
  3. Read result.residue, result.valid. Interpret false, null and empty lists using the distinctions below; they can be valid outputs.

Require each word from 0 to 65,535, add with exact integers and repeatedly fold high bits into the low 16 bits. Return residue and valid only when residue equals 65,535.1

Input fieldMeaning and representationAccepted input
wordswords.List of finite numbers; at most 128 entries
Output fieldInterpretation
resultObject containing the named outputs below.
result.residueThe residue value under the stated formula or text convention.
result.validFlag for valid under the exact condition described above.
json
{
  "input": {
    "words": [
      65534,
      1
    ]
  },
  "output": {
    "result": {
      "residue": 65535,
      "valid": true
    }
  }
}

Limitations and assumptions

  • Word construction, byte order, odd-byte padding and pseudoheaders must already be correct. An empty list gives residue zero and false; the test does not establish authenticity.
  • All declared input fields are required and unexpected top-level fields are rejected. Numbers must be finite; lists are limited to 128 entries and ordinary text fields to 8,192 UTF-16 code units, with tighter limits where stated.
  • JSON text inputs must parse within bounded nesting and size limits. Numeric outputs outside the safe finite range are rejected; large exact integer results use decimal strings. Indexes and half-open spans are zero-based unless a rank is explicitly described as one-based.

Alternative or Complementary methods

Use the complete specified checksum algorithm and independent test vectors when verifying a payload. Field packing, parameter shape and arithmetic agreement are separate checks; none supplies cryptographic authenticity.

References

  1. Tool behavior and example: Internet Checksum Residue Check — tool.io

Similar or alternative tools

Don't forget to set a bookmark for tool.io!
Privacy | Imprint | Cookies