<commit_before># AntiDDoS
Automatically scan tcp/udp connections, find bad IPs and ban them with iptables.

# How to use
```
cd /usr/local
wget https://github.com/yeezon/AntiDDoS/archive/master.zip
unzip master.zip
mv AntiDDoS-master/ ddos
cd ddos
chmod +x ddos.sh
./ddos.sh -c
```

# Config
Please view `ddos.conf`.

You could set `EMAIL_TO` with your email address.
And when there is ip banned, you would recieve an email.
To enable email sending, you should config smtp in your server:
Open config file:
`vi /etc/mail.rc`

Add the following content:
*The `[]` means parameter, you should drop in your config.*
```
set from=[name-<EMAIL>]
set smtp=[smtp.server.net]
set smtp-auth-user=[user name]
set smtp-auth-password=[password]
set smtp-auth=login
```
Save and quit with:`:wq`<commit_msg>edit README<commit_after># AntiDDoS
Automatically scan tcp/udp connections, find bad IPs and ban them with iptables.

# How to use
```
cd /usr/local
wget https://github.com/yeezon/AntiDDoS/archive/master.zip
unzip master.zip
mv AntiDDoS-master/ ddos
cd ddos
chmod +x ddos.sh
./ddos.sh -c
```

# Config
Please view `ddos.conf`.

You could set `EMAIL_TO` with your email address.
And when there is ip banned, you would recieve an email.
To enable email sending, you should config smtp in your server.

Open config file:

`vi /etc/mail.rc`

Add the following content:
*The `[]` means parameter, you should drop in your config.*
```
set from=[<EMAIL>]
set smtp=[smtp.server.net]
set smtp-auth-user=[user name]
set smtp-auth-password=[password]
set smtp-auth=login
```
Save and quit with:

`:wq`
{'fraction_non_alphanumeric': 0.11813013265950727, 'fraction_numerical': 0.0, 'mean_word_length': 4.315436241610739, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3031959', 'n_tokens_mistral': 576, 'n_tokens_neox': 556, 'n_words': 201}