🌐 Web version available at wraith.mdrashedulhasan.me — use the browser-based interface for a quick demo without any local setup.
# 1. Clone and install
git clone https://github.com/rashedhasan090/wraith.git
cd wraith
pip install -e .
# 2. Set API key (pick one)
export OPENAI_API_KEY="sk-..."
# OR
export ANTHROPIC_API_KEY="sk-ant-..."
# OR (no key needed — fully offline)
ollama pull llama3
# 3. Verify installation
wraith version
wraith config --show# Use the included intentionally vulnerable Flask app
cd demos/vulnerable_flask_app
pip install flask flask-jwt-extended# Full code scan with verbose reasoning output
wraith scan code ./demos/vulnerable_flask_app \
--verbose \
--output demo-report.html \
--format html \
--rl-strategy ucb1- Agent initialisation — point out each agent spinning up with its role
- Recon phase — "it maps the attack surface first, like a human pentester would"
- RL selection — "watch the UCB1 scores — it's picking which vuln classes to hunt based on past experience"
- Live reasoning — "every line prefixed with the agent name shows you exactly what it's thinking"
- Findings — "SQL injection, weak JWT, path traversal — all with reasoning chains"
- RL update — "after the scan, Q-values update — next time it'll be smarter"
# Show what the RL learned
wraith rl-stats
# Show detailed findings
wraith report demo-results.json --format markdown# Test an LLM endpoint for OWASP LLM Top 10 vulnerabilities
wraith redteam https://your-test-llm-api.com/chat \
--verbose \
--attacks prompt_injection,jailbreak,data_exfil,excessive_agency- Attack vector selection — RL picks which LLM attack to try first
- Prompt injection attempts — watch crafted payloads being sent
- Results — which attacks succeeded, which were blocked
- Reasoning — "the agent explains WHY it chose each payload and what the response indicates"
# Scan 1: First target — RL is exploring (high ε)
wraith scan code ./demos/vulnerable_flask_app --rl-strategy epsilon_greedy
# Scan 2: Different target — RL starts exploiting learned patterns
wraith scan code ./another-target --rl-strategy epsilon_greedy
# Show how the policy evolved
wraith rl-stats --compare- First scan — lots of exploration, some random strategy picks
- Second scan — notice how it's faster, picks better strategies
- RL stats — "Q-values converging, exploration rate decreasing, policy stabilising"
# Generate comprehensive report
wraith report demo-results.json \
--format html \
--output wraith-final-report.html
# Show attack chains
wraith chains demo-results.json --verbose- HTML report — professional, shareable, with severity breakdown
- Attack chain visualisation — multi-step paths from individual findings
- Reasoning transparency — click into any finding to see the full chain
- Remediation priorities — ordered by risk × exploitability
| Question | Answer |
|---|---|
| "How is this different from ChatGPT?" | "10 specialised agents with RL exploration, not one-shot LLM queries. They collaborate, learn, and produce auditable reasoning chains." |
| "Does this actually find real vulns?" | "Yes — the agents use real LLM reasoning on real code/targets. Every finding includes the reasoning chain so you can verify." |
| "Can I use my own LLM?" | "Yes — supports OpenAI, Anthropic, or any local Ollama model. Fully offline capable." |
| "What about false positives?" | "The reasoning chain lets you audit every finding. The RL system also learns to deprioritise low-confidence findings over time." |
| "Is the RL actually useful?" | "After 5-10 scans on similar tech stacks, scan efficiency improves ~30% — it learns which attack vectors are worth pursuing." |
| "How is this safe to use?" | "All PoCs use benign payloads. The tool is designed for authorised testing. RL data stays local." |
If the live LLM API is slow or unavailable:
# Switch to local Ollama (no internet needed)
wraith config --provider ollama --model llama3
# Or use the web version (no local setup required)
# → https://wraith.mdrashedulhasan.me/
# Or use the pre-recorded demo output
python demos/replay_demo.py