jkstraw_44238
Jun 18, 2008Nimbostratus
regex in iRules
Hello,
Please be patient with me - I am not the iRule guy on our team 🙂
We are using iRules primarily for redirecting URI's to specific pools - we do this with something similar to:
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::uri]] {
"/site1*" -
"/site2*" -
"/site3*" -
"/site4*" {
pool Test_Pool
}
}
}
We have found that in our environment there are a number of security related issues (mainly fingerprinting) we need to address.
I would like to follow the philosophy of "block everything and allow only what is required" instead of being reactive and "allowing everything and blocking what problems as they occur".
To accomplish this I was hoping it would be possible to use regular expressions to accomplish this. That is - the regular expression would only allow "/site1*" but not "//site1*".
Is something like this possible with iRules?