Forum Discussion
Michael_Powell1
Oct 04, 2010Nimbostratus
OK my logic was broken. I wanted to check source IP address and destination URI then permit for a private address and redirect for a public address. Otherwise permit all other traffic. I have resolved it as follows:
when HTTP_REQUEST {
if { [matchclass [IP::remote_addr] equals $::private_net] && [HTTP::uri] contains "/uri_string_at/"}{
return
}
elseif {
[HTTP::uri] contains "/uri_string_a/"
}{
HTTP::redirect "http://www.example.com/"
}
else {
return
}
}
Thanks anyway for looking :-)