XZ decompression doesn't like SHA-256 checksums #676

Closed
opened 2026-01-29 22:15:42 +00:00 by claunia · 1 comment
Owner

Originally created by @ms264556 on GitHub (Mar 7, 2025).

I think, since the XZ code doesn't actually run an block checksums, the fix would simply be skipping the correct number of bytes?

PR is here: https://github.com/adamhathcock/sharpcompress/pull/901.

Originally created by @ms264556 on GitHub (Mar 7, 2025). I think, since the XZ code doesn't actually run an block checksums, the fix would simply be skipping the correct number of bytes? PR is here: [https://github.com/adamhathcock/sharpcompress/pull/901](https://github.com/adamhathcock/sharpcompress/pull/901).
Author
Owner

@ms264556 commented on GitHub (Mar 7, 2025):

Actually, by reference to section 2.1.1.2 of the specification, the number of bytes formula just needs a tweak (since it currently returns 16 bytes for SHA-256 and should return 32).

I'll update my PR with the formula.

@ms264556 commented on GitHub (Mar 7, 2025): Actually, by reference to section 2.1.1.2 of [the specification](https://tukaani.org/xz/xz-file-format.txt), the number of bytes formula just needs a tweak (since it currently returns 16 bytes for SHA-256 and should return 32). I'll update my PR with the formula.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/sharpcompress#676