โก Cyber-Sentinel: AI-Enhanced SQLMap GUI
A premium, dark luxury GUI for SQLMap with integrated AI analysis capabilities. Built with Python and CustomTkinter for a modern, sleek interface.
๐ฏ Features
Core Functionality
- Real-time Terminal Output: Live streaming of SQLMap execution with syntax highlighting
- Visual Configuration: Intuitive controls for all SQLMap parameters
- Non-blocking Execution: Threaded subprocess management keeps UI responsive
- AI-Powered Analysis: Integrated OpenAI/Anthropic for intelligent vulnerability analysis
AI Analyst Panel
- Real-time Model Selector: Switch between AI providers and models on-the-fly
- Multiple AI Models: Support for GPT-4, GPT-3.5, Claude 3 Opus, Sonnet, and Haiku
- Analyzes SQLMap output in plain English
- Suggests optimal tamper scripts for detected WAFs
- Provides actionable recommendations for exploitation
- Explains errors and issues encountered
Dark Luxury Design
- Theme: "Obsidian Night" - Deep matte black with neon cyan accents
- Typography: Monospace fonts (Cascadia Code/JetBrains Mono)
- Components: Rounded corners, semi-transparent overlays, animated elements
- Colors:
- Background:
#0B0B0B (Primary), #1a1a1a (Secondary)
- Accents:
#00F2FF (Cyan), #FFD700 (Gold)
๐ Prerequisites
Required
- Python 3.8+
- SQLMap: Must be installed and accessible in PATH
# Install via pip
pip install sqlmap
# Or clone from GitHub
git clone https://github.com/sqlmapproject/sqlmap.git
Optional (for AI features)
- OpenAI API Key or Anthropic API Key
๐ Installation
-
Clone or download this repository
-
Install Python dependencies
pip install -r requirements.txt
-
Set up API keys (optional)
Create a .env file or set environment variables:
# For OpenAI
set OPENAI_API_KEY=your_openai_api_key_here
# For Anthropic
set ANTHROPIC_API_KEY=your_anthropic_api_key_here
-
Run the application
๐ฎ Usage
Basic Workflow
-
Enter Target URL
- Input the vulnerable URL with parameter (e.g.,
http://example.com/page?id=1)
-
Configure Scan Parameters
- Risk Level (1-3): Higher risk = more aggressive tests
- Level (1-5): Higher level = more extensive tests
- Tamper Script: Select evasion technique for WAF bypass
- Random User-Agent: Randomize HTTP User-Agent header
- Batch Mode: Automatically answer prompts (recommended)
-
Additional Arguments
- Add custom SQLMap flags (e.g.,
--dbs --threads=5)
-
Start Scan
- Click "๐ START SCAN" to begin
- Monitor real-time output in terminal
- Stop anytime with "๐ STOP" button
-
AI Analysis
- Click "๐ ANALYZE OUTPUT" to get AI insights
- Receive vulnerability explanations and recommendations
Example Configurations
Basic Database Enumeration
Target: http://testphp.vulnweb.com/artists.php?artist=1
Risk: 1
Level: 1
Additional Args: --dbs --batch
WAF Bypass Attempt
Target: http://example.com/page?id=1
Risk: 2
Level: 3
Tamper: space2comment
Random Agent: โ
Additional Args: --random-agent --batch
Full Database Dump
Target: http://example.com/page?id=1
Risk: 1
Level: 1
Additional Args: -D database_name --dump --batch
๐๏ธ Architecture
Project Structure
sqlmap gui/
โโโ main.py # Entry point
โโโ ui.py # GUI implementation (CustomTkinter)
โโโ logic.py # SQLMap wrapper & subprocess management
โโโ ai_analyzer.py # AI integration (OpenAI/Anthropic)
โโโ config.py # Configuration & theme settings
โโโ requirements.txt # Python dependencies
โโโ README.md # Documentation
Key Components
SQLMapWrapper (logic.py)
- Manages subprocess execution
- Streams output in real-time
- Handles command building and process lifecycle
AIAnalyzer (ai_analyzer.py)
- Integrates with OpenAI or Anthropic APIs
- Analyzes scan output for vulnerabilities
- Suggests tamper scripts for WAF bypass
CyberSentinelUI (ui.py)
- Modern dark-themed interface
- Real-time terminal with syntax highlighting
- Responsive controls and status indicators
โ๏ธ Configuration
Customizing Theme
Edit config.py to modify colors and UI settings:
COLORS = {
'bg_primary': '#0B0B0B', # Main background
'accent_cyan': '#00F2FF', # Primary accent
'accent_gold': '#FFD700', # Secondary accent
# ... more colors
}
Changing AI Provider
In config.py:
AI_SETTINGS = {
'provider': 'openai', # or 'anthropic'
'openai_model': 'gpt-4',
'anthropic_model': 'claude-3-sonnet-20240229',
}
SQLMap Path
If SQLMap is not in PATH, modify logic.py:
def _find_sqlmap(self) -> str:
return 'C:\\path\\to\\sqlmap.py' # Your SQLMap path
๐ Security Notes
โ ๏ธ Important: This tool is for authorized security testing only.
- Only test systems you have permission to assess
- Unauthorized testing may be illegal in your jurisdiction
- Use responsibly and ethically
- Keep API keys secure and never commit them to version control
๐ Troubleshooting
SQLMap Not Found
โ ERROR: SQLMap not found!
Solution: Install SQLMap or add it to your PATH
pip install sqlmap
# or
set PATH=%PATH%;C:\path\to\sqlmap
AI Analysis Unavailable
โ ๏ธ AI Analysis unavailable. Please configure API key.
Solution: Set environment variable for your chosen provider
set OPENAI_API_KEY=your_key_here
GUI Not Displaying Correctly
Solution: Ensure CustomTkinter is properly installed
pip install --upgrade customtkinter
Font Not Found
Solution: The app will fall back to system default if Cascadia Code is unavailable. To install:
- Windows: Download from Microsoft
- Linux:
sudo apt install fonts-cascadia-code
๐จ Screenshots
Main Interface
- Dark luxury theme with neon cyan accents
- Real-time terminal output with color coding
- Intuitive configuration panel
AI Analyst Panel
- Intelligent vulnerability analysis
- Plain English explanations
- Actionable recommendations
๐ License
This project is provided as-is for educational and authorized security testing purposes.
๐ค Contributing
Contributions are welcome! Areas for improvement:
- Database tree view visualization
- Export scan results to JSON/XML
- Scan history and session management
- Additional AI providers
- Custom tamper script editor
๐ Resources
๐ Acknowledgments
- SQLMap team for the amazing tool
- CustomTkinter for the modern UI framework
- OpenAI & Anthropic for AI capabilities
Made with โก by AI | For Ethical Hackers & Security Researchers