Man-in-the-Middle Attack Simulation

Lab Status: Running

MAN-IN-THE-MIDDLE ATTACK

See what happens when communication is intercepted.

Traffic Interception Interactive Simulation Simulation Only
ℹ️
Educational Visual Simulation Only

This demonstration visually illustrates packet transit and eavesdropping using fictional data. No actual network packets are captured, and no real proxy or ARP spoofing is executed. Do not enter real emails, credentials, or personal information.

Communication Controls

Configure fictional participants, payload, and protocol mode
Sample Payloads:
Animation Speed:
NETWORK ARCHITECTURE

Communication Pipeline & Simulated Interception Point

Certificate: Not Applicable (HTTP)
💻
ALICE
Sender Endpoint
192.168.1.10
Idle
🌐
NETWORK
Gateway / Wi-Fi Access Point
192.168.1.1
Routing Ready
🕵️
SIMULATED ATTACKER
Eavesdropping Observation Point
Passive Sniffer (Promiscuous Mode)
Observer Standing By
🖥️
BOB
Recipient Endpoint
192.168.1.50
Awaiting Message
● SIMULATED OBSERVER'S INTERCEPTED STREAM
Passive Observer
[Observation Point Idle] Click "Send Message" to dispatch a packet through the simulated network path.

Interception Vulnerability: When data travels without TLS encryption over unencrypted HTTP, any device on the network segment (such as an open coffee shop Wi-Fi) can inspect packet payloads using promiscuous sniffing.

● BOB'S INBOX & DECRYPTION VERIFICATION
Endpoint B
[Awaiting Incoming Transmission] Bob has not received any packet yet.

Recipient Perspective: Bob receives the message in both scenarios. However, in HTTP mode Bob has no guarantee of confidentiality or sender authenticity. In HTTPS mode, TLS guarantees confidentiality, integrity, and verified endpoint identity.

Real-Time Transmission Event Log

session.event_stream · simulation 0 events
[00:00:00] [SYSTEM] Visual MITM Simulation initialized in local demonstration mode.
[00:00:00] [READY] Ready to simulate message transmission. Select connection mode and click "Send Message".

Comparison Matrix: Insecure vs. Secured Communication

Demonstrate Both Modes
🔓

INSECURE COMMUNICATION (HTTP)

No transport encryption
  • ✕
    Message readable to an unauthorized observer

    Data packets travel in plaintext format (ASCII / UTF-8) across intermediate network devices.

  • ✕
    No transport encryption

    Transmissions on TCP port 80 carry zero cryptographic protection.

  • ✕
    No certificate or identity validation

    Neither party verifies that the peer is who they claim to be, enabling impersonation.

  • ✕
    Tampering without detection

    An intermediary can alter payload contents in flight with no cryptographic hash mismatch.

Mode not yet tested
🔒

SECURED COMMUNICATION (HTTPS / TLS)

End-to-end transport layer security
  • ✓
    Message protected in transit by TLS

    Modern authenticated ciphers (e.g. AES-256-GCM or ChaCha20-Poly1305) render payload unreadable.

  • ✓
    Certificate validation

    Public-key infrastructure (X.509 certificates) authenticates server identity, preventing rogue proxies.

  • ✓
    Unauthorized observer cannot read the protected message

    An eavesdropper captures only pseudo-random ciphertext with zero exposure of message contents.

  • ✓
    Message integrity verification

    Cryptographic authentication tags (MACs) ensure any packet tampering is immediately rejected.

Mode not yet tested

Educational Deep Dive: Man-in-the-Middle (MITM) Attacks

University Cybersecurity Curriculum
What is a Man-in-the-Middle (MITM) attack?

A Man-in-the-Middle (MITM) attack occurs when an unauthorized entity secretly positions themselves between two communicating parties (such as a client browser and a web server). The attacker gains the capability to eavesdrop (sniff) on the traffic, and potentially alter or inject messages without either party realizing the conversation has been compromised.

Key Insight: In classic MITM attacks, both parties believe they are talking directly and privately to one another. The attacker acts as an invisible relay or eavesdropper.
How can interception happen on computer networks?

Interception can happen at several physical and logical layers of the networking stack:

  • ARP Spoofing / Cache Poisoning: On local Ethernet or Wi-Fi subnets, an attacker sends falsified Address Resolution Protocol messages linking their MAC address with the default router's IP address, directing all local traffic through the attacker's machine.
  • Rogue Wi-Fi Access Points (Evil Twin): An attacker broadcasts a Wi-Fi network with the exact SSID of a legitimate hotspot. When victims connect, all their uplink traffic traverses the attacker's gateway.
  • DNS Spoofing / Hijacking: Malicious actors forge domain name resolution answers, redirecting users navigating to a legitimate site towards an attacker-controlled intermediate proxy.
  • Packet Sniffing: In shared transmission media (such as unencrypted wireless channels or old network hubs), network interface cards in promiscuous mode can capture every broadcast frame.
Why does public Wi-Fi introduce significant risks?

Public Wi-Fi networks (cafes, airports, hotels) often lack client isolation and strong layer-2 encryption. This means:

  • Any connected user shares the exact same radio broadcast medium as everyone else.
  • Without WPA3-Enterprise or individual client encryption keys, raw radio packets can be sniffed by anyone nearby with a Wi-Fi adapter.
  • Attackers can easily pose as the gateway router using simple tools, intercepting every HTTP transmission before forwarding it onward.
Defense Rule: Never transmit sensitive passwords, sessions, or personal data over plaintext HTTP. On public networks, always insist on HTTPS or an authenticated VPN tunnel.
What do HTTPS and Transport Layer Security (TLS) protect?

HTTPS (HTTP over TLS) provides three essential cryptographic guarantees for data in transit:

  1. Confidentiality (Encryption): Traffic is encrypted with robust symmetric ciphers (e.g. AES-GCM or ChaCha20). Even if an eavesdropper captures the raw frames, they only see pseudo-random ciphertext.
  2. Integrity (Tamper Resistance): Each record includes a Message Authentication Code (MAC) or AEAD tag. If a man-in-the-middle modifies even a single bit in transit, the recipient's TLS stack detects the corruption and terminates the session.
  3. Authentication (Peer Identity): The server proves its identity through a digital certificate signed by a trusted Certificate Authority (CA), verifying that the client is connected to the genuine entity.
Why does certificate validation matter so crucially?

Encryption alone is not enough without authentication. If an attacker sits between Alice and Bob, the attacker could establish one TLS connection with Alice and another separate TLS connection with Bob (acting as a terminating proxy).

Digital Certificate Validation defeats this:

  • The server must present an X.509 certificate issued by a trusted root CA present in the client's trust store.
  • The certificate domain (Common Name / SAN) must strictly match the destination host.
  • The server must prove possession of the private key corresponding to the certificate's public key.
  • If an attacker tries to inject a forged or self-signed certificate, modern browsers display prominent security warnings and refuse to connect unless overridden.