karnehe
karnehe

Reputation: 325

Apache2 + Mod_Evasive, only for one virtual host?

I am trying to utilize the mod_evasive for apache2 for one virtualhost only but it appears no matter what i do the module is loaded on the entirety of apache.

I looked through the docs and i cannot find any switch to disable mod evasive in it's own configuration allowing me to enable it only for specific vhosts.

I understand that i could simply do put the default config to ridiculous numbers making it never trigger/ban on the default and then do specific configurations for certain areas i would want it to trigger but that would be a performance hog having evasive run on everything.

How do i go about this? Do i need to put the site that needs to be behind mod evasive on a completely separate apache2 server?

Upvotes: 1

Views: 2150

Answers (1)

eyeonall
eyeonall

Reputation: 31

Ran into the same problem with proxying Jira and Confluence. They send so many requests it was always blocking. Ended up leaving mod_evasive at the global level and putting the following for vhosts I don't want to block and it has been working:

<IfModule mod_evasive24.c>
    DOSBlockingPeriod 0
</IfModule>

Upvotes: 1

Related Questions