Skip to content

Optionally (?) use a pure-rust zstd and/or xz2 implementations

The async-compression crate uses the zstd and xz2 crates, which are bindings to the C implementations of these compression algorithms.

That's well and good, but it would be good to provide a pure-rust implementation as an alternative, if one exists. This should probably be behind a feature.

Doing this port isn't a blocker for anything, since the zstd and xz2 algorithms are optional in the Tor protocol.

Porting to native rust here could help us on wasm/wasi environments.