fix
This commit is contained in:
parent
dc8ae34e82
commit
9e549d1df3
22
bots.txt
22
bots.txt
@ -1,3 +1,7 @@
|
|||||||
|
97.145.164.161
|
||||||
|
2605:6400:10:1fe::666
|
||||||
|
2001:470:79c9:100:5054:ff:fe66:12ba
|
||||||
|
97.145.164.161
|
||||||
167.172.244.121
|
167.172.244.121
|
||||||
185.224.128.59
|
185.224.128.59
|
||||||
66.249.66.9
|
66.249.66.9
|
||||||
@ -2327,3 +2331,21 @@
|
|||||||
213.180.203.28
|
213.180.203.28
|
||||||
85.208.96.204
|
85.208.96.204
|
||||||
87.250.224.54
|
87.250.224.54
|
||||||
|
66.249.66.89
|
||||||
|
5.255.231.106
|
||||||
|
2600:3c06::f03c:94ff:fe41:45f8
|
||||||
|
139.216.224.10
|
||||||
|
2600:3c06::f03c:94ff:fe41:45f8
|
||||||
|
2a03:4000:56:cd0:18ac:15ff:fe8c:3f1b
|
||||||
|
20.97.191.251
|
||||||
|
2a03:2880:13ff:29::face:b00c
|
||||||
|
2a03:2880:13ff:29::face:b00c
|
||||||
|
2a03:2880:13ff:29::face:b00c
|
||||||
|
2a03:2880:13ff:29::face:b00c
|
||||||
|
66.249.66.83
|
||||||
|
85.208.96.196
|
||||||
|
167.172.244.121
|
||||||
|
66.249.66.83
|
||||||
|
85.208.96.196
|
||||||
|
2a03:90c0:114::2fb
|
||||||
|
2001:41d0:d:36d3::1
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
facebookexternalhit
|
||||||
YandexBot
|
YandexBot
|
||||||
PetalBot
|
PetalBot
|
||||||
Amazonbot
|
Amazonbot
|
||||||
|
66
firewall2.sh
66
firewall2.sh
@ -431,65 +431,18 @@ module-go() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
module-home() {
|
module-akkoma() {
|
||||||
SEARCH_SPAM=$(grep $2 $NGINX_ACCESS | grep -E "timelines/public|timelines/home" | grep $1 | wc -l)
|
SEARCH_SPAM=$(grep $2 $NGINX_ACCESS | grep -E "api/v1/instance|api/v1/notifications|api/v1/accounts|api/v2/search|timelines/public|timelines/home|/api/v1/accounts" | grep $1 | wc -l)
|
||||||
CHECK=$(cat $NFT_CACHE | sort -u | grep $1)
|
|
||||||
if [[ "$SEARCH_SPAM" -gt 10 ]]; then
|
|
||||||
echo "module-home: $IP $CHECK $COUNT"
|
|
||||||
if [ "$CHECK" = "" ]; then
|
|
||||||
ipBlockParser "$1"
|
|
||||||
echo $1 >>$TMP_BLOCK
|
|
||||||
message "module-home Spam Attack! $1"
|
|
||||||
echo "module-home: Spam $1"
|
|
||||||
else
|
|
||||||
echo "module-homhomee: Ignoring Duplicate IP: $1"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
module-christi() {
|
|
||||||
SEARCH_SPAM=$(grep $2 $NGINX_ACCESS | grep -E "ChristiJunior" | grep $1 | wc -l)
|
|
||||||
CHECK=$(cat $NFT_CACHE | sort -u | grep $1)
|
|
||||||
if [[ "$SEARCH_SPAM" -gt 10 ]]; then
|
|
||||||
echo "module-christi: $IP $CHECK $COUNT"
|
|
||||||
if [ "$CHECK" = "" ]; then
|
|
||||||
ipBlockParser "$1"
|
|
||||||
echo $1 >>$TMP_BLOCK
|
|
||||||
message "module-christi: Spam Attack! $1"
|
|
||||||
echo "module-christi: Spam $1"
|
|
||||||
else
|
|
||||||
echo "module-christi: Ignoring Duplicate IP: $i"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
module-meow() {
|
|
||||||
SEARCH_SPAM=$(grep $2 $NGINX_ACCESS | grep -E "meow" | grep $1 | wc -l)
|
|
||||||
CHECK=$(cat $NFT_CACHE | sort -u | grep $i)
|
CHECK=$(cat $NFT_CACHE | sort -u | grep $i)
|
||||||
if [[ "$SEARCH_SPAM" -gt 5 ]]; then
|
if [[ "$SEARCH_SPAM" -gt 30 ]]; then
|
||||||
echo "$IP $CHECK $COUNT"
|
echo "$IP $CHECK $COUNT"
|
||||||
if [ "$CHECK" = "" ]; then
|
if [ "$CHECK" = "" ]; then
|
||||||
ipBlockParser "$1"
|
ipBlockParser "$1"
|
||||||
echo $1 >>$TMP_BLOCK
|
echo $1 >>$TMP_BLOCK
|
||||||
message "module-meow: Spam Attack! $1"
|
message "module-accounts: Spam Attack! $i"
|
||||||
echo "module-meow: Spam $1"
|
echo "module-accounts: Spam $1"
|
||||||
else
|
else
|
||||||
echo "module-meow: Ignoring Duplicate IP: $1"
|
echo "module-accounts: Ignoring Duplicate IP: $i"
|
||||||
fi
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
module-search() {
|
|
||||||
SEARCH_SPAM=$(grep $2 $NGINX_ACCESS | grep -E "GET /api/v2/search" | grep $1 | wc -l)
|
|
||||||
CHECK=$(cat $NFT_CACHE | sort -u | grep $i)
|
|
||||||
if [[ "$SEARCH_SPAM" -gt 5 ]]; then
|
|
||||||
echo "$IP $CHECK $COUNT"
|
|
||||||
if [ "$CHECK" = "" ]; then
|
|
||||||
ipBlockParser "$1"
|
|
||||||
echo $1 >>$TMP_BLOCK
|
|
||||||
message "module-search: Spam Attack! $i"
|
|
||||||
echo "module-search: Spam $1"
|
|
||||||
else
|
|
||||||
echo "module-search: Ignoring Duplicate IP: $i"
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
@ -529,13 +482,10 @@ message() {
|
|||||||
watch() {
|
watch() {
|
||||||
echo "Scanning $DATE"
|
echo "Scanning $DATE"
|
||||||
echo
|
echo
|
||||||
IP=($(grep $DATE $NGINX_ACCESS | grep -Evi -f $CRAWLER_DB | grep -vi $MY_IP | grep -vi '127.0.0.1' | cut -d ' ' -f1 | sort -u))
|
IP=($(grep $DATE $NGINX_ACCESS | grep -Evi -f $SAFE_TRAFFIC | grep -Evi -f $CRAWLER_DB | grep -vi $MY_IP | grep -vi '127.0.0.1' | cut -d ' ' -f1 | sort -u))
|
||||||
|
|
||||||
for i in "${IP[@]}"; do
|
for i in "${IP[@]}"; do
|
||||||
module-home "$i" "$DATE"
|
module-akkoma "$i" "$DATE"
|
||||||
module-search "$i" "$DATE"
|
|
||||||
module-meow "$i" "$DATE"
|
|
||||||
module-christi "$i" "$DATE"
|
|
||||||
module-lightning "$i" "$DATE"
|
module-lightning "$i" "$DATE"
|
||||||
module-php "$i" "$DATE"
|
module-php "$i" "$DATE"
|
||||||
module-go "$i" "$DATE"
|
module-go "$i" "$DATE"
|
||||||
|
Loading…
Reference in New Issue
Block a user