Guardian is an enterprise-grade AI-powered penetration testing automation framework that combines the strategic reasoning of Google Gemini with battle-tested security tools to deliver intelligent, adaptive security assessments.
Features β’ Installation β’ Quick Start β’ Documentation β’ Contributing
Guardian is designed exclusively for authorized security testing and educational purposes.
- β Legal Use: Authorized penetration testing, security research, educational environments
- β Illegal Use: Unauthorized access, malicious activities, any form of cyber attack
You are fully responsible for ensuring you have explicit written permission before testing any system. Unauthorized access to computer systems is illegal under laws including the Computer Fraud and Abuse Act (CFAA), GDPR, and equivalent international legislation.
By using Guardian, you agree to use it only on systems you own or have explicit authorization to test.
- Multi-Agent Architecture: Specialized AI agents (Planner, Tool Selector, Analyst, Reporter) collaborate for comprehensive security assessments
- Strategic Decision Making: Google Gemini analyzes findings and determines optimal next steps
- Adaptive Testing: AI adjusts tactics based on discovered vulnerabilities and system responses
- False Positive Filtering: Intelligent analysis reduces noise and focuses on real vulnerabilities
15 Integrated Security Tools:
- Network: Nmap (comprehensive port scanning), Masscan (ultra-fast scanning)
- Web Reconnaissance: httpx (HTTP probing), WhatWeb (technology fingerprinting), Wafw00f (WAF detection)
- Subdomain Discovery: Subfinder (passive enumeration), Amass (active/passive mapping)
- Vulnerability Scanning: Nuclei (template-based), Nikto (web vulnerabilities), SQLMap (SQL injection), WPScan (WordPress)
- SSL/TLS Testing: TestSSL (cipher analysis), SSLyze (advanced configuration analysis)
- Content Discovery: Gobuster (directory brute forcing), FFuf (advanced web fuzzing)
- Scope Validation: Automatic blacklisting of private networks and unauthorized targets
- Audit Logging: Complete transparency with detailed logs of all AI decisions and actions
- Human-in-the-Loop: Configurable confirmation prompts for sensitive operations
- Safe Mode: Prevents destructive actions by default
- Multiple Formats: Markdown, HTML, and JSON reports
- Executive Summaries: Non-technical overviews for stakeholders
- Technical Deep-Dives: Detailed findings with evidence and remediation steps
- AI Decision Traces: Full transparency into AI reasoning process
- Asynchronous Execution: Parallel tool execution for faster assessments
- Workflow Automation: Predefined workflows (Recon, Web, Network, Autonomous)
- Customizable: Create custom tools and workflows via simple YAML/Python
- Python 3.11 or higher (Download)
- Google Gemini API Key (Get Free API Key)
- Git (for cloning repository)
Guardian can intelligently use these tools if installed:
| Tool | Purpose | Installation |
|---|---|---|
| nmap | Port scanning | apt install nmap / choco install nmap |
| masscan | Ultra-fast scan | apt install masscan / Build from source |
| httpx | HTTP probing | go install github.com/projectdiscovery/httpx/cmd/httpx@latest |
| subfinder | Subdomain enum | go install github.com/projectdiscovery/subfinder/v2/cmd/subfinder@latest |
| amass | Network mapping | go install github.com/owasp-amass/amass/v4/...@master |
| nuclei | Vuln scanning | go install github.com/projectdiscovery/nuclei/v3/cmd/nuclei@latest |
| whatweb | Tech fingerprint | gem install whatweb / apt install whatweb |
| wafw00f | WAF detection | pip install wafw00f |
| nikto | Web vuln scan | apt install nikto |
| sqlmap | SQL injection | pip install sqlmap / apt install sqlmap |
| wpscan | WordPress scan | gem install wpscan |
| testssl | SSL/TLS testing | Download from testssl.sh |
| sslyze | SSL/TLS analysis | pip install sslyze |
| gobuster | Directory brute | go install github.com/OJ/gobuster/v3@latest |
| ffuf | Web fuzzing | go install github.com/ffuf/ffuf/v2@latest |
| arjun | Parameter discovery | pip install arjun |
| xsstrike | Advanced XSS | git clone ... |
| gitleaks | Secret scanning | go install github.com/zricethezav/gitleaks/v8@latest |
| cmseek | CMS detection | pip install cmseek |
| dnsrecon | DNS enumeration | pip install dnsrecon |
Note: Guardian works without external tools but with limited scanning capabilities. The AI will adapt based on available tools.
Easiest and fastest way to get started with all 15 security tools pre-installed!
# Clone repository
git clone https://github.com/zakirkun/guardian-cli.git
cd guardian-cli
# Create .env file with your API key
echo "GOOGLE_API_KEY=your_api_key_here" > .env
# Build Docker image (one-time, ~5 minutes)
docker-compose build
# Run Guardian
docker-compose run --rm guardian recon --domain example.comBenefits:
- β All 15 tools pre-installed (nmap, httpx, nuclei, sqlmap, etc.)
- β No manual tool installation required
- β Consistent environment across all systems
- β Isolated and secure
See Docker Guide for advanced usage.
git clone https://github.com/zakirkun/guardian-cli.git
cd guardian-cliLinux/macOS:
python3 -m venv venv
source venv/bin/activate
pip install -e .Windows:
python -m venv venv
.\venv\Scripts\activate
pip install -e .# Linux/macOS
python -m cli.main init
# Windows
python -m cli.main init
# or use the batch launcher
.\guardian.bat initDuring initialization, you'll be prompted for your Gemini API key. Alternatively, create a .env file:
echo "GOOGLE_API_KEY=your_api_key_here" > .env# List available workflows
python -m cli.main workflow list
# Dry run (see execution plan without running)
python -m cli.main recon --domain example.com --dry-run# Fast security check of a web application
python -m cli.main workflow run --name web --target https://example.com# Full network penetration test
python -m cli.main workflow run --name network --target 192.168.1.0/24# Discover and analyze subdomains
python -m cli.main recon --domain example.com# Let AI decide each step dynamically
python -m cli.main workflow run --name autonomous --target example.com# Create HTML report from previous scan
python -m cli.main report --session 20251222_120000 --format html# View AI decision-making process
python -m cli.main ai --lastWindows Users: Use
python -m cli.mainor.\guardian.batinstead ofguardian
- Quick Start Guide - Get up and running in 5 minutes
- Docker Deployment Guide - Run Guardian with Docker (recommended)
- Command Reference - Detailed documentation for all commands
- Configuration Guide - Customize Guardian's behavior
- Creating Custom Tools - Build your own tool integrations
- Workflow Development - Create custom testing workflows
- Available Tools - Overview of integrated tools
- Multi-Agent System: Planner β Tool Selector β Analyst β Reporter
- AI-Driven: Google Gemini for strategic decision-making
- Modular: Easy to extend with new tools and workflows
guardian-cli/
βββ ai/ # AI integration (Gemini client, prompts)
βββ cli/ # Command-line interface
β βββ commands/ # CLI commands (init, scan, recon, etc.)
βββ core/ # Core agent system
β βββ agent.py # Base agent
β βββ planner.py # Planner agent
β βββ tool_agent.py # Tool selection agent
β βββ analyst_agent.py # Analysis agent
β βββ reporter_agent.py # Reporting agent
β βββ memory.py # State management
β βββ workflow.py # Workflow orchestration
βββ tools/ # Pentesting tool wrappers
β βββ nmap.py # Nmap integration
β βββ masscan.py # Masscan integration
β βββ httpx.py # httpx integration
β βββ subfinder.py # Subfinder integration
β βββ amass.py # Amass integration
β βββ nuclei.py # Nuclei integration
β βββ sqlmap.py # SQLMap integration
β βββ wpscan.py # WPScan integration
β βββ whatweb.py # WhatWeb integration
β βββ wafw00f.py # Wafw00f integration
β βββ nikto.py # Nikto integration
β βββ testssl.py # TestSSL integration
β βββ sslyze.py # SSLyze integration
β βββ gobuster.py # Gobuster integration
β βββ ffuf.py # FFuf integration
β βββ ... # 15 tools total
βββ workflows/ # Workflow definitions (YAML)
βββ utils/ # Utilities (logging, validation)
βββ config/ # Configuration files
βββ docs/ # Documentation
βββ reports/ # Generated reports
Edit config/guardian.yaml to customize:
ai:
provider: gemini
model: gemini-1.5-pro
temperature: 0.2
pentest:
safe_mode: true # Prevent destructive actions
require_confirmation: true # Confirm before each step
max_parallel_tools: 3 # Concurrent tool execution
scope:
blacklist: # Never scan these
- 127.0.0.0/8
- 10.0.0.0/8We welcome contributions! Here's how:
# Fork and clone
git clone https://github.com/zakirkun/guardian-cli.git
cd guardian-cli
# Install dev dependencies
pip install -e ".[dev]"
# Run tests
pytest tests/
# Format code
black .- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
- π οΈ New Tool Integrations - Add more security tools
- π Custom Workflows - Share your workflow templates
- π Bug Fixes - Report and fix issues
- π Documentation - Improve guides and examples
- π§ͺ Testing - Expand test coverage
See CONTRIBUTING.md for detailed guidelines.
- Web Dashboard for visualization
- PostgreSQL backend for multi-session tracking
- MITRE ATT&CK mapping for findings
- Plugin system for custom modules
- Integration with CI/CD pipelines
- Additional AI models support (Claude, GPT-4)
- Mobile app for on-the-go assessments
Import Errors
# Reinstall dependencies
pip install -e . --force-reinstallAPI Rate Limits
- Free tier: 2 requests/minute
- Switch to paid tier or implement request throttling
- Configure in
config/guardian.yaml:ai.rate_limit: 60
Tool Not Found
# Check tool availability
which nmap
which httpx
# Install missing tools (see Prerequisites)Windows Command Not Found
# Use full command
python -m cli.main --help
# Or use batch launcher
.\guardian.bat --helpFor more help, open an issue.
This project is licensed under the MIT License - see the LICENSE file for details.
MIT License
Copyright (c) 2025 Guardian Project
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction...
- Google Gemini - AI capabilities
- LangChain - AI orchestration framework
- ProjectDiscovery - Open-source security tools (httpx, subfinder, nuclei)
- Nmap - Network exploration and security auditing
- The Security Community - Tool developers and researchers
- GitHub Issues: Report bugs or request features
- Discussions: Join community discussions
- Documentation: Read the docs
- Security: Report vulnerabilities privately to security@example.com
If you find Guardian useful, please consider giving it a star! β
Guardian - Intelligent, Ethical, Automated Penetration Testing
Made with β€οΈ by the Security Community