Forum Discussion
Chris_Miller
Feb 10, 2011Altostratus
Sure.
You'd have a string type data group called something like "domainredirects." In that group, you'd have a string like "xxx.domaina.com" with a value like "xxx.domainb.com." Then, your rule would look something like this:
when HTTP_REQUEST {
if { [class match [HTTP::host] eq domainredirects] } {
HTTP::redirect "https://[class search - value domainredirects eq [HTTP::host]]" }
}
Otherwise, if your scheme is as simple as xxx.domaina.com > xxx.domainb.com, then a string command would be more efficient. All depends on how many characters you're changing I suppose.