Notes from taking the supplied binaries apart, plus the decision each one drove. This is analysis, not a port: no code was copied, and no proprietary format was reimplemented.
CreateFileA, SetFilePointer,
GetFileTime/SetFileTime, MoveFileA, FindFirstFileA — it rewrites files
in place and preserves timestamps. BigFile::* error strings show a custom
buffered IO layer built on Win32 handles.Number of bits that can be saved: %s (%0.3f bytes) — it measures its
work in bits, not bytes, and rewrites only when a whole byte is saved
unless /b is given./a scan all files regardless of
extension, /b rewrite on bit savings, /c keep GZIP/ZIP comments, /d keep
timestamps, /f force rewrite, /k keep all chunks, /r recurse, /s silent,
/v verbose. Slashes and dashes both accepted; wildcards allowed; explicit
note that it will not touch archives nested inside archives.Kosh equivalent: kosh optimize. Same guarantee (byte-identical content,
smaller deflate stream) but the container is rebuilt from parsed structures
rather than patched, so CRC/Adler fields, extra fields and local headers stay
consistent. --dry-run replaces guesswork; --strip is the /k inverse;
--backup replaces the implicit in-place rewrite.
/4, /14, /29, /41… (Borland/GCC
section naming). Statically linked: zopfli, libpng 1.6.18, lodepng, libjpeg,
optipng’s opngreduc, a C++ stdlib with std::regex/std::future.ECT [Options] File, with -strip, -gzip, -quiet,
-M1–-M5 (compression level, default 1), and advanced --strict
(strict losslessness), --mt-deflate[=i] (per-block multithreading)..ungz outputs.Kosh equivalent: kosh optimize --level 1|2|3. Same algorithms, rebuilt:
Zopfli for the entropy layer, our own PNG filter analysis (adaptive or forced,
ranked with fast zlib before spending Zopfli), real metadata stripping, and
--jobs to parallelise across files. Empty files and already-optimal files are
handled instead of refused.
Usage: Wabbie e/d inputfile outputfile.bscBlockHeader, lz4Stream_body,
dec64table, MTFTable, rankHistory, runHistory, num_indexes — that is
BSC (a Burrows–Wheeler + MTF + entropy coder) with LZ4 framing.Kosh equivalent: kosh pack / kosh unpack. Keeps the good part — blocks
that compress independently, so it parallelises — and drops the GPU dependency:
Zstandard (with internal threading), Brotli or LZMA per block, a table of
contents, per-entry SHA-256, selective extraction, symlinks and safe paths.
.rsrc (console UI art). Type names in the metadata are obfuscated
(private-use Unicode identifiers), so the IL is not readable without an
unpacking step; the string literals are likewise hidden.FileStream, BinaryWriter,
FileInfo, Directory, ConsoleKeyInfo, ConsoleColor — a console
splitter/joiner that reads a key from the user between operations.Kosh equivalent: kosh split / kosh join / kosh parts. Splitting by size
or by part count, but each part is hashed into a JSON manifest, so joining
verifies every part and the reassembled file. Works on any OS, streams with
constant memory, and refuses to silently produce a corrupt output.
Kosh equivalent: kosh archive plus the .kosh container. The workflow is
reproduced (one window, pick files, one output file, get them back) but the
formats are open: ZIP, tar, tar.gz, tar.zst, tar.xz and .kosh, each with a CLI
verb and a browser UI.
e_lfanew points at offset 4, the section table and data
directories are absent (pefile and dnfile both reject it), and the bytes
after the DOS stub are high-entropy. It looks like a protected or deliberately
scrambled stub rather than a program that can be read.| Concern | Originals | Kosh |
|---|---|---|
| Platform | Windows x86 only | Linux, macOS, Windows (pure Python + wheels) |
| Interface | Console flags or a GUI | One CLI and a local web UI over the same engine |
| Integrity | None / implicit | SHA-256 per part, per file, per container entry |
| Failure handling | In-place rewrite, no undo | Atomic temp-and-rename, --dry-run, --backup |
| Progress | Sparse or none | Live progress with throughput, JSON output for scripting |
| Scope | One job per program | Split, join, pack, unpack, archive, optimise, inspect |