Chenco_322726
Jun 13, 2017Nimbostratus
restrict website to only specific ip addresses on same VS
Hello Friends , I have many domains on the same VS . and i am trying to restrict the access to to only specific ip addresses the problem is i found some irules on google but the problem is that i have many domains on the same VS so it blocks every domain on the vs.
any help will be appreciated
You could create a data group with the allowed ip addresses, and then reference them in an iRule, that only matches if the host header is :
when HTTP_REQUEST { if { [HTTP::host] equals "www.example.com" } { Require client ip address to be present in datagroup (dg_example.com) for allowed source ip's if { ! [class match [IP::client_addr] eq dg_example.com] } { drop return } } }