lz4-frame · shipping · also LZ4 framing

LZ4 frame

An LZ4 frame wraps data blocks in a descriptor and end marker, with optional length, dictionary identification and integrity checks.

Related Observatory article: LZ4 frame on hesela.com

The frame API reports frame completion separately from consumed input and produced output. A complete first frame can leave another frame unread, while a truncated end marker can follow all expected payload bytes. [2]

A controlled liblz4 experiment swaps two independent blocks with their checksums intact. Block-only verification accepts the reordered frame; adding the original content checksum rejects it. Declared length alone does not detect this same-length rearrangement. [3]

Relations

related
Block-independent compression, Compression dictionary, Checksum, Skippable frame (Zstandard), Restore test

Citations

  1. LZ4 v1.9.4 public frame API: preferences and LZ4F_decompress completion contract (accessed 2026-10-18)
  2. Hesela: LZ4 frame checks, block order and completion (accessed 2026-10-18)

Further reading

  1. LZ4 Frame Format 1.6.4, pinned to v1.10.0: block independence, checksums and dictionaries (accessed 2026-10-18)
Sources & caveats
  • The synthetic experiment uses liblz4 1.9.4 and no dictionary; observations are not a corruption-rate estimate or security guarantee.

JSON: /data/terms/lz4-frame.json

Published by Hesela team · Updated

Report a correction · Editorial standards · Reuse guidance

Cite this page
Hesela team. LZ4 frame. Hesela. 2026-10-18. https://hesela.dev/terms/lz4-frame/