Expand description
CRC-verified zip extraction primitives. Generic, CRC-verified zip extraction primitives.
These are the reusable archive operations shared by every Thunderstore mod
manager: extracting a package zip with per-entry CRC32 verification and
path-traversal protection, deciding whether a downloaded version differs
from what is already on disk, and parsing the Owner-Name-Version.zip
filename convention. Where the extracted files ultimately land is install
policy and lives in the caller (see crate::install).
Structs§
- Extract
Limits - Resource limits enforced while extracting an archive, to defend against decompression bombs (an archive that is small on disk but expands to an enormous number of entries or bytes).
Functions§
- extract_
zip - Extracts a zip archive to
dest_dirwith per-entry CRC32 verification and the defaultExtractLimits. - extract_
zip_ with_ limits - Extracts a zip archive to
dest_dirwith per-entry CRC32 verification, enforcing the suppliedExtractLimitsto defend against decompression bombs. - parse_
package_ filename - Parses a Thunderstore package zip filename of the form
Owner-Name-Version.zip. - should_
extract - Determines whether a mod should be (re)extracted based on version comparison.