Whitelist for IP range on ModSecurity 2.9 & Apache 2.4.3

apache-2.4cpanelmod-security

I'm try to add Google Ip range on white list for Mod Security

I use Cpanel+Apache 2.4+ModSecurity 2.9.0+OWASP Rules

On several post i se this conf

SecRule REMOTE_ADDR "@ipMatch XX.XX.XX.XX,66.249.64.0/19" "phase:1,nolog,allow,ctl:ruleEngine=Off"

But fail Only work if add a id:rule

SecRule REMOTE_ADDR "@ipMatch XX.XX.XX.XX,66.249.64.0/19" "phase:1,id:'981033',t:none,nolog,pass,ctl:ruleEngine=Off"

Best Answer

Ids became mandatory in ModSecurity 2.7: https://github.com/SpiderLabs/ModSecurity/wiki/Reference-Manual#id

So guessing the posts you picked this up from there predate this.

Note you should use an id in the range 1-99,999 and not 981033 which is reserved for the OWASP CRS rules.

Related Topic