Getting Started

Introduction

What Shell[SNIP] is and when to use it.

Introduction

ShellSNIP is a Shellcode Factory that generates PIC (Position Independent Code) shellcode from reusable NASM snippets, targeting Windows and Linux. Instead of hand-writing assembly for every payload, you assemble modular templates — recipes that reference reusable snippets — and let the tool handle parameter substitution, compilation via NASM, optional encoding, and validation.

What it does

ShellSNIP ships four built-in recipes:

RecipePurpose
execExecute a command (WinExec on Windows, execve on Linux)
dlexecDownload a remote payload and execute it
connectOpen a TCP reverse shell back to an attacker-controlled host
injectInject shellcode into a running process (CreateRemoteThread / ptrace)

Each recipe is built from snippets — reusable ASM blocks — resolved through a custom template engine that supports snippet inclusion, whitelisted Python helper calls, and parameter substitution.

Supported platforms

Templates are organized in {os}_{arch} directories. win_64 and posix_64 ship complete recipe and snippet sets; macos is accepted as a CLI/MCP option but has no template directory yet.

OS--os flagArchNASM format
Windowswin64win64
Linuxposix64elf64

How you can use it

  • CLI (generate.py) — generate, compile, encode, and write shellcode from the command line.
  • MCP server (server.py) — expose recipes, snippets, helpers, encoders, and compilation as tools to AI clients such as Claude Code, Cursor, or Windsurf.
  • Python API — import ShellSnip, TemplateManager, and the encoder classes directly into your own tooling.

Continue to Installation to set up the required toolchain.

Copyright © 2026