Master Reality SNI Scanner is a professional-grade, cross-platform tool designed for comprehensive testing of SNI (Server Name Indication) compatibility with the Reality protocol. Built with a modern client-server architecture, it enables security researchers, network administrators, and penetration testers to systematically evaluate SNI configurations across diverse network environments.
The tool addresses the critical challenge of identifying which SNI domains work reliably with Reality-based proxy configurations, allowing users to discover optimal settings for their specific network conditions.
- Batch Processing: Efficiently handles large SNI lists by processing them in configurable batches (default: 50 SNIs per batch)
- Dynamic Configuration: Automatically generates and applies Reality server configurations for each batch
- UUID Security: Generates cryptographically secure random UUIDs for each session
- Multi-Transport Support: Full compatibility with 7 transport protocols
- Port Management: Automatic port detection and conflict resolution
- RESTful API: Clean HTTP API for seamless client-server communication
- Parallel Testing: Multi-threaded testing with configurable worker count (1-20 workers)
- Five SNI Input Methods:
- Manual entry (one-by-one)
- File import (batch loading from text files)
- File import with Shuffle (random order testing) β¨ NEW in v2.1.0
- Auto-scan (discovers nearby SNI candidates)
- Default presets (common working SNIs)
- Smart Result Sorting: Working SNIs automatically sorted by latency (lowest first) β¨ NEW in v2.1.0
- Partial Results on Interrupt: Ctrl+C shows and saves results from completed tests β¨ NEW in v2.1.0
- User-Friendly Output: Clean message when no working SNIs are found β¨ NEW in v2.1.0
- Real-time Results: Live feedback with latency metrics and success/failure status
- Formatted Output: Beautiful ASCII tables for improved readability
- Comprehensive Logging: Detailed results saved with timestamps
- Cross-Platform: Works on Windows, Linux, and macOS
- Intelligent Detection: Automatically detects installed dependencies
- One-Command Setup: Installs Python packages and Xray-core
- Status Reporting: Shows clear installation status table
| Protocol | Description | Use Case |
|---|---|---|
| TCP | Standard TCP protocol | Maximum compatibility |
| WebSocket (WS) | WebSocket tunneling | CDN-friendly connections |
| gRPC | High-performance RPC | Low-latency requirements |
| HTTP/2 (h2) | HTTP/2 framing | Web traffic simulation |
| XHTTP | Advanced HTTP multiplexing | Recommended for optimal performance |
| QUIC | UDP-based protocol | Mobile networks, reduced latency |
| SplitHTTP | Fragmented HTTP requests | Anti-detection, CDN environments |
- Linux (Ubuntu, Debian, CentOS, RHEL, Arch)
- macOS (Intel and Apple Silicon)
- Windows (10, 11, Server editions)
- Python 3.6+
- Xray-core (v1.8.0+)
- Root/Sudo privileges (for Xray management)
- OpenSSL
- 1GB+ RAM (recommended)
- 10GB+ disk space (for logs)
- Python 3.6+
- Xray-core (v1.8.0+)
- 512MB+ RAM
- Internet connection to target server
# Clone repository
git clone https://github.com/AminDaProgrammer/Master_Reality_SNI_Scanner.git
cd Master_Reality_SNI_Scanner
# Auto-install dependencies
python3 dependencies-autoInstaller.py
# Start server (on VPS)
sudo python3 server-sniScanner.py
# Start client (on testing machine)
python3 client-sniScanner.py --server <SERVER_IP>π‘ Windows Note:
On Windows,python3may not be recognized by default.
The interpreter is often available aspy,python, orpython.exe.
Replace anypython3command with the correct one on your system (e.g., usepyinstead ofpython3).
# Install Python dependencies
pip install requests cryptography
# Install Xray-core
bash -c "$(curl -L https://github.com/XTLS/Xray-install/raw/main/install-release.sh)" @ install| Use Case | Description |
|---|---|
| SNI Discovery | Find working SNI domains for Reality configurations |
| Network Testing | Evaluate SNI performance across different networks |
| Security Auditing | Verify SNI integrity and compatibility |
| Optimization | Identify fastest SNI for specific locations |
| Research | Analyze SNI filtering patterns in various regions |
Results are saved in the results/ directory with human-readable filenames:
Master_SNI_Scanner_2025_01_15_14_30_25.txt
- Summary Statistics: Total tested, working, failed, success rate
- Working SNIs Table: Ranked list with latency metrics (sorted by latency - lowest first)
- Failed SNIs Table: List of non-functional domains
- Configuration Links: Ready-to-use VLESS configuration strings
If you press Ctrl+C during testing, partial results are automatically:
- Displayed in the terminal (same format as complete scan)
- Saved to
results/directory (same format as complete scan) - Includes all tested SNIs with their status and latency
- Random UUID Generation: Each session uses cryptographically secure UUIDs
- No Hardcoded Credentials: All configurations generated dynamically
- Minimal Attack Surface: API exposed only during active testing
- Cleanup Routine: Xray processes terminated after testing
- No Persistent Data: All logs and configs are temporary
Master_Reality_SNI_Scanner/
βββ server-sniScanner.py # Server module - Reality config management
βββ client-sniScanner.py # Client module - SNI testing & reporting
βββ dependencies-autoInstaller.py # Auto installer - Cross-platform dependencies
βββ results/ # Test results directory (auto-created)
β βββ Master_SNI_Scanner_*.txt
β βββ Master_SNI_Scanner_working_*.txt
βββ domains.txt # list of domains
βββ README.md # Project documentation
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β CLIENT β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β SNI Input: Manual | File | File+Shuffle | Auto | Def β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β
β β Transport Selection: TCP | WS | gRPC | h2 | XHTTP... β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β
β β Parallel Testing: Worker Pool (1-20 threads) β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β
β β Results: Real-time table + File export (sorted by ping)β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
β HTTP API (Port: 8080)
βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β SERVER β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β Batch Processing: 50 SNIs per batch β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β
β β Reality Config Builder: UUID, Private/Public Keys β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β
β β Xray Manager: Start/Stop/Restart Service β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β
β β Transport Config: TCP | WS | gRPC | h2 | XHTTP... β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
| Metric | Value |
|---|---|
| SNIs per Batch | 50 (configurable) |
| Parallel Workers | 5-10 (configurable) |
| Test Duration (50 SNIs) | ~30-45 seconds |
| Test Duration (500 SNIs) | ~5-8 minutes |
| Memory Usage | ~150-300MB |
| CPU Usage | ~25-50% (with 5 workers) |
- Graceful Degradation: Continues testing even if individual SNIs fail
- Automatic Recovery: Restores previous config on server failure
- Timeout Management: Configurable timeouts prevent hanging
- Resource Cleanup: Automatic termination of Xray processes
- User Interrupt:
Ctrl+Cgracefully shows and saves partial results β¨ NEW in v2.1.0
We welcome contributions! Please follow these guidelines:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
MIT License - Free for personal and commercial use.
MIT License
Copyright (c) 2025 Master Reality SNI Scanner Team
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, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
# Install dependencies
python3 dependencies-autoInstaller.py
# Start server (Linux/macOS)
sudo python3 server-sniScanner.py
# Start server (Windows - as Administrator)
python server-sniScanner.py
# Start client (interactive mode)
python3 client-sniScanner.py
# Start client with specific server
python3 client-sniScanner.py --server 192.168.1.100 --api-port 8080- Xray-core - Core proxy framework
- VLESS Protocol - Protocol documentation
- 3x-ui - Xray panel (inspiration)
Master Reality SNI Scanner - Empowering security professionals with reliable SNI testing for Reality protocol deployments.