TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

ZFS checksum flaw: Corruption may be left unnoticed

9 pointsby PaulCarrack5 months ago

3 comments

magicalhippo5 months ago
I think the headline is misleading.<p>The function in question only used by the dataset send&#x2F;receive functionality to compute the checksum of the resume token, and by the zdb debug tool which is used to inspect the filesystem.<p>Importantly, it&#x27;s not the function used to compute the checksum of the blocks on disk.<p>The resume token contains a header which includes the checksum in question as well as the length of the decompressed data in the token, followed by compressed data. The code checks that the length of the decompressed data matches the value stored in the header.<p>So, this means that the possibility for corruption is only when receiving a dataset and the token is corrupted in a way where Zlib decompresses the correct amount of data, but the last few bytes are incorrect.
ggm5 months ago
Corruption in the last 4 bytes of a checksummed block. So, it&#x27;s about the rate of detected corruption in the block overall and the distribution of corrupt bits, and the calculated odds of a corrupt 4 byte block end.<p>In terabytes, non trivially non zero I guess. Since the git submission has &quot;my calculated version&quot; you could imagine doing a post hoc comparison block by block on a tainted FS. Painfully slow I bet.
rurban5 months ago
Very common with overly optimized hash functions, such as fletcher4. The remaining bytes mod 4 are just ignored. BSD&#x27;s nbperf does the same. Very sloppy