Rafish_129330
Apr 23, 2018Nimbostratus
irule that block host to all ip address except specific ip
Hello,
I need irule that block access to some url for all ip address except specific ip, i wrote the irule and i success to block the url but the problem is that the irule block access to all ip address and i need access from 10.10.10.10
when HTTP_REQUEST { if { [string tolower [HTTP::host]] starts_with "test1.technion.ac.il" || [HTTP::host] starts_with "test2.technion.ac.il" || [HTTP::host] starts_with "test3.technion.ac.il" || [HTTP::host] starts_with "test4.technion.ac.il" and [IP::addr[IP::remote_addr] not equals 10.10.10.10/255.255.255.255] } then { HTTP::respond 404 "Not Found" "Connection" "close" log local0. "This Connetion blocked By iRule My-iRule" } }
Any Suggestions ?
Regards Rafi