1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
[]
= "fstool"
= "0.4.21"
= "2024"
# Floor is the edition-2024 minimum (1.85) bumped to 1.88 by the
# `purecrypto` dependency (encrypted-DMG crypto), whose MSRV is 1.88 as of
# 0.6.14.
= "1.88"
= "Build disk images and filesystems (ext2/3/4, MBR, GPT) from a directory tree and TOML spec, in the spirit of genext2fs."
= "MIT"
= "https://github.com/KarpelesLab/fstool"
= "README.md"
= ["filesystem", "ext4", "ext2", "gpt", "image"]
= ["filesystem", "command-line-utilities"]
# Keep the published crate to the library + CLI source. The browser UI and CI
# config are repo-only and would just bloat the crates.io tarball. (The wasm
# bindings live in-crate at src/wasm.rs behind the `wasm` feature.)
= ["/web", "/.github"]
[]
= "fstool"
# `cdylib` is what wasm-bindgen consumes to build the browser bundle (see the
# `wasm` feature + src/wasm.rs); `rlib` is what the CLI and other Rust crates
# link against. Native builds emit both — the cdylib is a small extra artifact.
= ["cdylib", "rlib"]
= "src/lib.rs"
[[]]
= "fstool"
= "src/bin/fstool/main.rs"
[]
# Compression codecs for SquashFS reads and `.tar.<algo>` streaming I/O.
# Enabled by default; disable with `default-features = false` and pick
# a subset if you want to slim the binary or avoid a C-bundled build.
#
# Archive backends (zip / cpio / ar) are always compiled — they add no new
# dependencies (zip's DEFLATE rides the `gzip` feature; cpio/ar need no
# codec). Every other archive format has a read-only reader behind its own
# per-format feature (`cab`, `amiga-lzx`, `lha`, `arc`, `sit`, `sevenz`,
# `rar`); each enables only the compcol codecs it can use today and returns a
# clean `Unsupported` for methods whose codec hasn't landed in compcol yet.
= ["gzip", "xz", "lzma", "lz4", "zstd", "lzo", "cab", "amiga-lzx", "lha", "arc", "sit", "sevenz", "rar", "dmg-bzip2", "dmg-lzfse", "dmg-encrypted", "readline"]
# Line editing + command history for the interactive `fstool shell` (↑/↓
# history, Ctrl-A/E, etc.) via `rustyline`. On by default; disable it
# (`default-features = false`) to drop the dependency — the shell then falls
# back to a plain line-buffered reader. No effect on piped/non-TTY input.
= ["dep:rustyline"]
# WebAssembly bindings (src/wasm.rs) for the browser UI. Pulls in
# `wasm-bindgen`; build with `--no-default-features --features
# wasm,<codecs…> --target wasm32-unknown-unknown`, then run `wasm-bindgen`.
# Off by default so native library/CLI builds don't carry the dependency.
= ["dep:wasm-bindgen", "dep:console_error_panic_hook"]
# Every codec is served by `compcol` (one uniform crate): gzip/zlib/deflate/
# xz/lzma/zstd/lz4/lzo, plus the CAB + Amiga-LZX archive codecs and the DMG
# bzip2/lzfse decoders. The `gzip` feature also covers zip DEFLATE, DMG zlib,
# and HFS+ decmpfs; lz4 uses compcol's raw block (SquashFS) + canonical frame
# (tar); lzo uses compcol's raw LZO1X block; lzma is the `.lzma` alone codec.
= ["dep:compcol", "compcol/gzip", "compcol/zlib", "compcol/deflate"]
= ["dep:compcol", "compcol/xz"]
= ["dep:compcol", "compcol/lzma"]
= ["dep:compcol", "compcol/lz4"]
# Microsoft Cabinet (.cab) reader: Store/MSZIP/LZX/Quantum folders decode
# via compcol. Read-only.
= ["dep:compcol", "compcol/deflate", "compcol/lzx", "compcol/quantum"]
# Amiga LZX (.lzx) reader: Store + LZX (compcol amiga_lzx) groups. Read-only.
= ["dep:compcol", "compcol/amiga_lzx"]
# LHA / LZH (.lzh) reader (read-only): walks level-0/1/2 headers. `-lh0-`
# store decodes today; the lh1/4/5/6/7 LZSS+Huffman methods list but read as
# Unsupported pending an `lha` codec in compcol (will add `compcol/lha`).
= []
# SEA ARC (.arc) reader (read-only): walks the flat header chain. Stored
# methods 1/2 decode today; the compressed methods (RLE90 / squeeze / crunch /
# squash) list but read as Unsupported pending ARC codecs in compcol.
= []
# StuffIt (.sit) reader (read-only): classic `SIT!` container — data-fork
# method 0 (store) decodes; compressed methods + StuffIt 5 list/detect but
# read as Unsupported pending StuffIt codecs in compcol.
= []
# 7-Zip (.7z) reader (read-only): parses the container + single-coder folders
# (Copy / LZMA / BZip2 / Deflate via compcol; solid folders sliced per
# substream). LZMA2 / BCJ filters / PPMd / multi-coder / encryption list but
# read as Unsupported pending raw-LZMA2 + branch-filter codecs in compcol.
= ["dep:compcol", "compcol/lzma", "compcol/bzip2", "compcol/deflate"]
# RAR reader (read-only): RAR5 store + compressed via compcol's rar5 decoder,
# including solid groups (decoded as one continuous stream; a sequential walk
# such as repack decompresses the group once). (RAR4 would add compcol/rar1+
# rar2+rar3 later.)
= ["dep:compcol", "compcol/rar5"]
= ["dep:compcol", "compcol/zstd"]
= ["dep:compcol", "compcol/lzo"]
# DMG chunk codecs beyond the always-available zero / raw / zlib / ADC set,
# decoded via compcol (bzip2 + lzfse decoders). Gated so a slim build can
# drop them. (`lzfse_rust` is a dev-dependency used only to generate the
# lzfse test vector — compcol's LZFSE is decode-only.)
= ["dep:compcol", "compcol/bzip2"]
= ["dep:compcol", "compcol/lzfse"]
# Password-protected DMG read support (`encrcdsa` v2). Served by the
# `purecrypto` crate (AES-CBC, 3DES-EDE3-CBC via Cbc64, HMAC-SHA1, SHA-1,
# PBKDF2) — pure-Rust, no foreign code. Gated so a slim build can drop it.
= ["dep:purecrypto"]
# FUSE adapter: enables the `fstool mount` subcommand which exposes an
# ext{2,3,4} image as a userspace filesystem via libfuse (Linux) or
# macFUSE (macOS). Off by default so the core build doesn't need a C
# FUSE library on the host; opt in with `--features fuse`.
= ["dep:fuser"]
[]
= "2"
= "0.4"
= { = "1", = ["v4"] }
= "1"
= { = "4", = ["derive"] }
= { = "1.0.228", = ["derive"] }
= "1"
= "1.1.2"
= "0.6.8"
# Unicode NFD + default case folding for the APFS drec hash function.
# Volumes formatted with APFS_INCOMPAT_NORMALIZATION_INSENSITIVE
# (the macOS default for user data volumes) store drec keys with a
# 22-bit CRC32C of the NFD-normalised (optionally case-folded) name;
# our writer computes it via these crates. Both unicode-normalization
# and caseless are maintained under unicode-rs and MIT/Apache.
= "0.1"
= "0.2"
# CP949 (Korean) ↔ UTF-8 for the GRF backend (Gravity Ragnarok archives
# store filenames in CP949). encoding_rs's `EUC_KR` label is the WHATWG
# alias that covers CP949 — the spec mapping is identical in practice.
= "0.8"
# Compression codecs — all optional and feature-gated. Pure-rust where
# possible (flate2 via miniz_oxide, lz4_flex, lzma-rs); zstd and lzo
# pull in bundled C source.
# compcol: uniform no_std codec collection serving gzip/zlib/deflate/xz/zstd
# /lz4/lzo plus the CAB codecs. `std` is always on (for the `io` Read/Write
# adapters); per-algorithm features are added by fstool's feature flags.
= { = "0.6.10", = true, = false, = ["std"] }
# Line editing + persistent history for the interactive shell. Optional, behind
# the `readline` feature; the bin enables it by default. Pure-Rust line editor.
= { = "15", = true }
# Encrypted DMG (encrcdsa v2) crypto — `purecrypto`, a pure-Rust no_std
# toolkit (KarpelesLab, MIT). Opt-in via the `dmg-encrypted` feature; we
# pull only the symmetric/hash/kdf modules (`kdf` re-enables `hash` +
# `cipher`), not its TLS/PQC/RSA surface.
= { = "0.6.14", = true, = false, = ["std", "cipher", "hash", "kdf"] }
# FUSE adapter — Linux uses libfuse, macOS uses macFUSE. Off by default
# (see the `fuse` feature). `fuser` is the maintained successor to
# `fuse-rs` and tracks the libfuse 3.x ABI. We enable the default
# `libfuse` feature so the build links against the system FUSE
# library; running `cargo build --features fuse` therefore requires
# libfuse-dev (Linux) or macFUSE (macOS) installed on the host.
= { = "0.16", = true, = ["libfuse"] }
# Needed on Unix for the BLKGETSIZE64 / DKIOCGETBLOCKCOUNT ioctls used to
# query the size of a block device, plus the O_EXCL open flag that refuses
# devices with a mounted partition.
[]
= "0.2"
[]
= "3"
= "0.11"
# Test-only: an independent LZFSE *encoder* to generate fixtures that the
# production `compcol` LZFSE decoder must round-trip (compcol's LZFSE is
# decode-only). Not linked into the shipped binary.
= "0.2"
# wasm32 needs a browser randomness source for uuid v4 generation, plus the
# wasm-bindgen glue when the `wasm` feature is on.
[]
= { = "1", = ["v4", "js"] }
# Pinned to the wasm-bindgen CLI version CI installs; the crate and the CLI
# that post-processes the .wasm must match exactly.
= { = "=0.2.121", = true }
= { = "0.1", = true }