Skip to main content

vamp-icmp-shadow

Covert ICMP data channel for Red/Blue Team detection validation and IDS/IPS rule testing
VampSecure Labs · Security Research Division


Overview

vamp-icmp-shadow implements a covert data channel over ICMP for use in authorized Red/Blue Team lab environments. It demonstrates that the payload field of ICMP Echo Request packets can be used as a data exfiltration vector, bypassing network controls that filter only by protocol or port number without performing deep packet inspection on ICMP content.

The tool's primary purpose is defensive: validating that IDS/IPS rules (Snort, Suricata) correctly detect non-standard ICMP payloads, training Blue Team analysts to recognize the traffic pattern, and documenting the attack vector in network security audit reports. It must not be used outside of self-owned lab environments or without explicit written authorization.

Data is obfuscated via XOR with a shared key, encoded in Base64, prefixed with a magic marker (VSHDW:), and split into fixed-size chunks transmitted as individual ICMP Echo Request packets. The receiver side reassembles and decodes the stream.

Features

  • send mode — XOR-encrypts a message with the configured key, Base64-encodes it, fragments it into 200-byte chunks, and sends each chunk as an ICMP Echo Request (type=8) with sequential sequence numbers
  • listen mode — captures ICMP Echo Request packets via Scapy BPF filter icmp, verifies the VSHDW: magic prefix, decodes Base64, applies XOR to recover plaintext, and displays captured messages in Rich panels with source IP and sequence number
  • XOR + Base64 obfuscation — symmetric cipher (XOR key repeats cyclically); the same key decrypts: XOR(XOR(data, key), key) = data
  • Configurable key via --key parameter or --key-file (first line of file) — default key is VAMP_KEY_2026
  • Magic-prefix filtering — the receiver silently ignores all ICMP traffic that does not carry the VSHDW: prefix, making it quiet in mixed-traffic environments
  • Verbose mode (-v) shows all ICMP packets received including those without the magic prefix, useful for debugging IDS rule placement
  • Chunk-based fragmentation — messages longer than 200 obfuscated bytes are automatically split; the receiver accumulates chunks per source IP ordered by ICMP sequence number
  • Root privilege enforcement — exits with an error if not run as root, as raw packet capture requires CAP_NET_RAW
  • Rich console output: sender displays a per-packet table with payload preview, byte count, and status; receiver shows a panel per decoded message

Requirements

pip install -r requirements.txt
Package Version
scapy >= 2.5.0
rich >= 13.7.0

Standard library: argparse, base64, os, sys, time, datetime, pathlib.

Installation

git clone https://github.com/belky-me/vamp-icmp-shadow.git
cd vamp-icmp-shadow
pip install -r requirements.txt

Requires root or CAP_NET_RAW capability for both send and listen modes.

Usage

python vamp_icmp_shadow.py --help

Two subcommands are available: send and listen.

usage: vamp-icmp-shadow {send,listen} ...

subcommands:
  send      Send a message via the ICMP Shadow channel
  listen    Listen for incoming ICMP Shadow channel traffic

Examples

Send a short message to a lab target (default key):

sudo python vamp_icmp_shadow.py send -t 192.168.1.10 -d "shadow test"

Send a message with a custom XOR key:

sudo python vamp_icmp_shadow.py send -t 192.168.1.10 -d "exfil payload" -k "MY_SECRET_KEY"

Send using a key loaded from a file:

sudo python vamp_icmp_shadow.py send -t 192.168.1.10 -d "test" --key-file /etc/lab/icmp.key

Send with verbose output (shows per-packet errors and status):

sudo python vamp_icmp_shadow.py send -t 10.0.0.5 -d "blue team test" -v

Listen on interface eth0 for incoming Shadow channel traffic:

sudo python vamp_icmp_shadow.py listen -i eth0

Listen with a custom key and verbose mode (shows non-Shadow ICMP too):

sudo python vamp_icmp_shadow.py listen -i eth0 -k "MY_SECRET_KEY" -v

Listen using a key file:

sudo python vamp_icmp_shadow.py listen -i eth0 --key-file /etc/lab/icmp.key

Protocol Overview

Sender:
  plaintext → XOR(key) → Base64 → "VSHDW:" + B64_CHUNK
  Each chunk → ICMP Echo Request (type=8, seq=N, payload=VSHDW:...)

Receiver:
  ICMP Echo Request captured → check for "VSHDW:" prefix
  → Base64 decode → XOR(key) → plaintext
  → display with source IP and sequence number

Chunk size: 200 bytes of the obfuscated Base64 string per packet.
Inter-packet delay: 50 ms to avoid overwhelming the network stack.

Blue Team Detection Notes

This tool is designed to make its own traffic detectable. Example Suricata signature that fires on the VSHDW: magic prefix in ICMP payloads:

alert icmp any any -> any any (msg:"VampSecure ICMP Shadow channel"; \
  content:"VSHDW:"; itype:8; sid:9000001; rev:1;)

Use this tool to verify that your IDS signature correctly triggers before writing it into the production ruleset.

Part of VampSecure Labs Toolkit

This tool is part of the VampSecure Labs Security Toolkit — a collection of research-grade security tools for authorized penetration testing and red/blue team exercises.


© VampSecure Studios — VampSecure Labs Security Research Division
For authorized security testing only.

Metadata

Release files for vamp-icmp-shadow 1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for vamp-icmp-shadow 1.2
File Size Uploaded Provenance Actions
vamp_icmp_shadow-1.2.tar.gz 8.9 kB Without provenance Details for vamp_icmp_shadow-1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for vamp-icmp-shadow 1.2
File Interpreter ABI Platform Actions
vamp_icmp_shadow-1.2-py3-none-any.whl Python 3 none any Details for vamp_icmp_shadow-1.2-py3-none-any.whl

Total release size: 18.1 kB

Release files / vamp_icmp_shadow-1.2.tar.gz

Download URL vamp_icmp_shadow-1.2.tar.gz
Size 8.9 kB
Tags Source
SHA-256 checksum
How to use checksums
a3aa695bb8bb8e21b13f7ec1fe408c2dd72187acbb645ea7842ed8d681988394
BLAKE2b-256 checksum
How to use checksums
fb6bc64c6cd8b4d284296cdce81590fea3c6ac9742b84c70d3ed95955d9eb1a2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Release files / vamp_icmp_shadow-1.2-py3-none-any.whl

Download URL vamp_icmp_shadow-1.2-py3-none-any.whl
Size 9.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
478691a1098c427fef2298cbf7100a32625b8370f50476a7030470bab5540b89
BLAKE2b-256 checksum
How to use checksums
42b076be39a89ca15faf2ef2e13ef134f7500a707e5cc8b638c9baba79e955e2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Security for vamp-icmp-shadow 1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.2 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page