Exploit databaseDownload repository ZIP
GH-4a1ac11de6e692c6eba6f0fb33104c88
01luyicheng/cve-2026-99999-exploit
Sources for CVE-2026-99999
10 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files2
01luyicheng/cve-2026-99999-exploitRevision bf204ef8bb6f
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
host/setup_bridge.sh
Shell · 4,007 bytes#!/bin/bash
# CVE-2026-99999 — TAP Bridge Setup Script (Host Side)
# ======================================================
# Creates a bridge with a TAP device for exploit testing.
# Run on the HOST as root before starting the guest VM.
#
# Usage: sudo ./setup_bridge.sh [bridge-name] [tap-name] [ip-subnet]
# bridge-name: Name of bridge (default: br0)
# tap-name: Name of TAP device (default: tap0)
# ip-subnet: IP subnet in CIDR notation (default: 10.0.0.0/24)
#
# Teardown: sudo ./setup_bridge.sh --teardown
#
# NOTE: This script is for isolated lab environments only.
set -e
BRIDGE="${1:-br0}"
TAP="${2:-tap0}"
SUBNET="${3:-10.0.0.0/24}"
GW_IP="$(echo $SUBNET | sed 's|0/24|1|')"
teardown() {
echo "[*] Tearing down..."
ip link set "$TAP" down 2>/dev/null || true
ip link delete "$TAP" 2>/dev/null || true
ip link set "$BRIDGE" down 2>/dev/null || true
ip link delete "$BRIDGE" 2>/dev/null || true
echo "[+] Done."
exit 0
}
if [[ "$1" == "--teardown" || "$1" == "-t" ]]; then
teardown
fi
# ── Check root ────────────────────────────────────────────────────────────────
if [[ $EUID -ne 0 ]]; then
echo "[-] This script must be run as root (sudo)."
exit 1
fi
# ── Check dependencies ───────────────────────────────────────────────────────
for cmd in ip ss tc; do
if ! command -v $cmd &>/dev/null; then
echo "[-] Missing required command: $cmd"
exit 1
fi
done
echo "[*] Setting up TAP bridge for CVE-2026-99999 exploit testing"
echo " Bridge: $BRIDGE | TAP: $TAP | Subnet: $SUBNET | Gateway: $GW_IP"
# ── Clean up existing devices ─────────────────────────────────────────────────
ip link set "$TAP" down 2>/dev/null && ip link delete "$TAP" 2>/dev/null || true
ip link set "$BRIDGE" down 2>/dev/null && ip link delete "$BRIDGE" 2>/dev/null || true
# ── Create bridge ────────────────────────────────────────────────────────────
ip link add name "$BRIDGE" type bridge
ip link set "$BRIDGE" up
# ── Assign IP to bridge ───────────────────────────────────────────────────────
ip addr add "$GW_IP/24" dev "$BRIDGE"
# ── Create and attach TAP device ──────────────────────────────────────────────
ip link add name "$TAP" type tap mode tap
ip link set "$TAP" master "$BRIDGE"
ip link set "$TAP" up
# ── Enable forwarding and disable STP for fast startup ─────────────────────────
# (STP delay is fine for a test bridge with one port)
sysctl -w net.ipv4.ip_forward=1 2>/dev/null || true
# ── Show result ───────────────────────────────────────────────────────────────
echo ""
echo "[+] Bridge '$BRIDGE' is up with TAP '$TAP'"
echo " Bridge IP: $GW_IP/24"
echo " DHCP range: assign IPs in $SUBNET (gateway=$GW_IP)"
echo ""
echo " To start QEMU with TAP networking:"
echo " qemu-system-x86_64 \\"
echo " -netdev tap,id=net0,ifname=$TAP,vhost=on \\"
echo " -device virtio-net-pci,netdev=net0,mac=52:54:00:12:34:56 \\"
echo " ..."
echo ""
echo " To run leak detector:"
echo " python3 receive_and_dump.py --interface $TAP --packets 20 --verbose"
echo ""
echo " To teardown:"
echo " sudo $0 --teardown"