sudo apt update && sudo apt purge ufw firewalld -y && sudo apt install nftables git -y && git clone https://github.com/yuk1c/antiddos && cd antiddos && sudo ./antiddos-yuki && cd ..
This command removes UFW/firewalld completely as the script isn't compatible with them. Make sure you don't rely on them before running it.
The mandatory dependencies are nftables
(for the rules) and git
(so you can download the script, update it, etc.). Nothing else.
For the monitoring script, you'd need to have Python 3 installed.
- Ubuntu 22.04+
- Debian 11+ [Beta]
Probably compatible with other Debian-based distros. Use the newest LTS Ubuntu release for the script to perform at its best. Also, you can use the script on your Linux laptop, for example, so you'll care less about being targeted with L3-L4 attacks in public networks.
cd ~/antiddos && git pull && sudo ./antiddos-yuki && cd
sudo python3 monitoring.py
Add a rule to the beginning of the user-rules.nft file. Here's an example of one to allow TCP to port 25565 (for Minecraft servers):
add rule ip yuki-script prerouting tcp dport 25565 counter accept