cancel
Showing results for 
Search instead for 
Did you mean: 
Colin_Walker_12
Historic F5 Account

Problem this snippet solves:

Here is a straight-forward example of how you can avoid a location specific DDOS attack via iRules. This iRule inspects the Accept-Language header to get an idea of the source of the attack, and filters based on that.

Code :

when HTTP_REQUEST {
  if { [HTTP::uri] equals "/" }{
    #log "uri: [HTTP::uri] "
    HTTP::redirect "http://anotherserverpool"
  } elseif { [HTTP::uri] equals "/homepage.asp" } {
    #log "uri: [HTTP::uri] "
    HTTP::redirect "http://anotherserverpool"
  } elseif {[string tolower [HTTP::header "Accept-Language"]] contains "ru"} {
    HTTP::redirect "http://nullsite"
  } else {
    pool mypool
  }
}
Version history
Last update:
‎18-Mar-2015 15:24
Updated by:
Contributors