New in CWP Edge-LatestFree with every CWPpro licenceWebsites up to 300x faster

CWP now includes LSPHP, LSAPI-Cache and CWP Cage at no extra cost with all CWPpro licences. The LSAPI-Cache plugin is integrated into our WordPress and other script installers, and CWP Cage gives every user complete isolation. Available now in the CWP Edge-Latest version.

Get CWPpro ›

nginx mod-security block semrushbot

Started by russromei, December 05, 2022, 08:56:46 AM

Previous topic - Next topic

russromei

I'm trying to block crawlers and bots, specifically semrushbot
I am using centos on nginx
What path and file would I add this to?

SecRule REQUEST_HEADERS:User-Agent "@contains semrushbot" "id:'1000001',t:none,t:lowercase,deny,nolog,msg:'BAD BOT - Detected and Blocked. '"

DO I NEED THIS ONE?
SecRule REQUEST_HEADERS:User-Agent "@contains semrushbot/7" "id:'1000001',t:none,t:lowercase,deny,nolog,msg:'BAD BOT - Detected and Blocked. '"