CF-Shield: Automated Cloudflare DDoS Protection with Python

2025-06-23
CF-Shield: Automated Cloudflare DDoS Protection with Python

CF-Shield is a Python script that automatically detects and mitigates DDoS attacks on Cloudflare. It requires your Cloudflare email, API token, zone ID, and account ID. After installation, the script prompts you to set a CPU usage threshold, challenge type, and optional Discord, Slack, and Telegram notifications. It monitors CPU usage; if it exceeds the threshold, it automatically enables Cloudflare's WAF rules and disables them after the attack. This powerful tool helps protect your website from DDoS attacks.