Skip to content

Latest commit

 

History

History
133 lines (85 loc) · 3.6 KB

File metadata and controls

133 lines (85 loc) · 3.6 KB

ShellCraft

Banner Contributions Welcome Twitter URL Twitter URL YouTube URL Python Metasploit License

Shellcraft is a modular Windows payload construction framework designed for red team operations and offensive security research.

It focuses on shellcode-driven execution, compiling native Windows binaries using reproducible C/C++ templates and static toolchains.


Overview

Shellcraft automates the process of:

  • Consuming raw shellcode (msfvenom or external)
  • Injecting shellcode into native Windows payloads
  • Building a dropper + DLL execution chain
  • Producing statically linked Windows binaries

The project is intended to be auditable, hackable, and extensible, rather than a black-box payload generator.


Design Goals

  • Deterministic builds
  • Template-driven payloads
  • Minimal runtime dependencies
  • Explicit execution flow
  • Research-first, not “AV-bypass-first”

Architecture

shellcraft/
├── shellcraft.py # Entry point
├── sources/
│ ├── payload_dll.cpp # Shellcode loader (DLL)
│ ├── dropper.cpp # Dropper executable
│ └── DefenderWrite.cpp # Helper binary

Execution flow

  1. Shellcode is generated or loaded from disk
  2. Shellcode is embedded into payload_dll.cpp
  3. Payload DLL is compiled
  4. Dropper EXE is compiled
  5. Dropper stages execution on target

Shellcode Sources

Shellcraft supports two input methods:

msfvenom

shellcraft --msf <LHOST> <LPORT> -o payload.exe

Raw shellcode file

shellcraft -s shellcode.bin -o payload.exe
Shellcode is treated as opaque input.

No encoding, encryption, or mutation is applied by default.

Build Requirements

  • Linux
  • Python ≥ 3.8

Toolchain

Metasploit Framework (optional)

MinGW-w64 (x86_64-w64-mingw32-g++)

Output

payload.exe          # Dropper
payload.dll          # Shellcode DLL
DefenderWrite.exe    # Helper binary

All artifacts are designed to reside in the same directory at runtime.

Limitations

No evasion or obfuscation layer

No in-memory-only execution

No automatic privilege escalation

Detection by modern EDRs is expected

Shellcraft is a framework, not a finished weapon.

Use Case

Red team tradecraft experimentation

Payload development research

Windows execution-chain prototyping

Template-based payload engineering

❤️Supporters❤️

Stargazers repo roster for @HackScaleTeam/ShellCraft

Forkers repo roster for @HackScaleTeam/ShellCraft

Legal

This project is provided for authorized security testing and research only.

You are responsible for compliance with all applicable laws and engagement scopes.