2

I have this rewrite cond in .htaccess

RewriteCond %{REMOTE_ADDR} !^195.16.40.50

How to set RewriteCond by ip range from 192.168.0.0 to 192.168.32.255

Amit Verma
  • 40,709
  • 21
  • 93
  • 115
Naumov
  • 1,167
  • 9
  • 22

1 Answers1

2

This condition should match your ip range:

RewriteCond %{REMOTE_ADDR} ^195\.168\.([0-9]|[1-2][0-9]|3[0-2])\.[0-9]+$
Florian Lemaitre
  • 5,905
  • 2
  • 21
  • 44