My nginx
instance is getting hammered every couple of days by some bad bot using random query parameter values.
/var/log/nginx/access.log:209.107.204.224 - - [14/Mar/2023:16:01:42 +0100] "GET /?ttrp353217=ttrp540516 HTTP/1.1" 501 560 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36"
When it hits, it quickly causes resource starvation, and eventually HTTP 501/504 for regular customers.
The ttrp
query param name/value always contains a random number.
Is this some well-known bot?
Is there a way to configure nginx
to block requests containing specific query param regex? AFAIK, I can block the request if the query param exists, not if query param starting with prefix exists...
I blocked the address for the time being, but that one is likely to change.