The Witchcraft Compiler Collection provides command-line tools to transform, inspect, and script against ELF and other binaries on POSIX systems.
Overview
WCC is a suite of compilation-related utilities for binary analysis and transformation on GNU/Linux and other POSIX platforms. The collection is documented in an online user manual and installs via make after dependency packages such as capstone, bfd, elf, and readline libraries are present.
wld turns an ELF executable into a shared library through libification. wcc accepts binaries in formats supported by libbfd and emits ELF outputs, including relocatable objects produced by undoing linker work on executables or shared libraries. wsh is an embedded shell that loads shared libraries and dynamically linked ET_DYN executables into one address space and exposes their symbols to a Lua-based Punk-C scripting environment.
Auxiliary commands include wldd to print linker flags needed to relink a binary and wcch to generate C headers from exported symbols. wsh scripts can call functions from loaded programs, as shown in examples that hash strings using cryptographic routines from sshd. Cross-architecture analysis can combine wsh with user-mode emulation as described in the manual limits section.
Ubuntu and Debian package lists are documented for installing build dependencies. Core tools are intended for security research, reverse engineering, and unconventional linking workflows on ELF-centric systems, with partial support for PE and other formats through libbfd.
Key features
- ELF executable libification
- Binary-to-relocatable conversion
- Lua shell over loaded binaries
- Punk-C scripting interface
- Linker flag extraction
- C headers from binaries
- Reflection-like API calls
- Multi-format libbfd input
Use cases
- Reverse engineering ELF binaries
- Scripting against live program APIs
- Producing shared objects from executables
- Generating link flags and headers