With 4.2.8 update of iThemes Security, the bug still exist and wildcard character still not working in IP for:
? “Global settings” section =>”Lockout White List” field
? “Banned users” section => “Ban Hosts” field
To enable range of IPs, you can add to your .htaccess file IPs using the wildcard character (*) in this form:
# BEGIN PERSONNAL SETTINGS
# ===> RESTRICT ACCESS [BLOCKING] - BLACK LISTING
RewriteEngine On
Order allow,deny
# Using 1 wildcard character
SetEnvIF REMOTE_ADDR "^###\.###\.###\.*$" DenyAccess
SetEnvIF X-FORWARDED-FOR "^###\.###\.###\.*$" DenyAccess
SetEnvIF X-CLUSTER-CLIENT-IP "^###\.###\.###\.*$" DenyAccess
# Using 2 wildcard character
SetEnvIF REMOTE_ADDR "^###\.###\.*\.*$" DenyAccess
SetEnvIF X-FORWARDED-FOR "^###\.###\.*\.*$" DenyAccess
SetEnvIF X-CLUSTER-CLIENT-IP "^###\.###\.*\.*$" DenyAccess
# ===> ALLOW ACCESS [UNBLOCKING] - WHITE LISTING
# Using 1 wildcard character
SetEnvIF REMOTE_ADDR "^###\.###\.###\.*$" AllowAccess
SetEnvIF X-FORWARDED-FOR "^###\.###\.###\.*$" AllowAccess
SetEnvIF X-CLUSTER-CLIENT-IP "^###\.###\.###\.*$" AllowAccess
# Using 2 wildcard character
SetEnvIF REMOTE_ADDR "^###\.###\.*\.*$" AllowAccess
SetEnvIF X-FORWARDED-FOR "^###\.###\.*\.*$" AllowAccess
SetEnvIF X-CLUSTER-CLIENT-IP "^###\.###\.*\.*$" AllowAccess
Deny from env=DenyAccess
Allow from env=AllowAccess
Allow from all
# END PERSONNAL SETTINGS
here “###” are numbers from 0 to 255 and all the lines begining with “#…” are comments. For each rage of Ip you have to add a group of:
SetEnvIF REMOTE_ADDR "^###\.###\.###\.*$"
SetEnvIF X-FORWARDED-FOR "^###\.###\.###\.*$"
SetEnvIF X-CLUSTER-CLIENT-IP "^###\.###\.###\.*$"
…adding at the end “DenyAccess” to Black list or “AllowAccess” to White list.
Like this you can allow or block range of IPs to stop hacking attempts from some countries (like China, Russsia, Ukraine…)
I hope this feature will work in next iThemes Security update.
L..