Forum Discussion
jgranieri
Aug 17, 2016Nimbostratus
there are two ways to do this. one is to use datagroups in the irule and use class match statements. in the datagroups specify the strings u want to match on. below is the straigh irule reference u can either use a pool as an action or simply add a reject statement then and default for all other actions
when HTTP_REQUEST {
if { ( [string tolower [HTTP::uri]] contains "/testconnect/") && ( [string tolower [HTTP::header User-Agent]] starts_with "java/" ) } {
pool _something
} else {
HTTP::respond 200 content "not allowed..."
reject
}
}