Forum Discussion
Brad_Parker_139
Nacreous
Looks like you used "TCP::remote_port" in your first if. That is what caused your loop since its not being matched. Try this:
when HTTP_REQUEST {
if { [TCP::local_port] eq 80 && !([string tolower [HTTP::uri]] eq "/articles/2015/09/09/something.aspx") }
{
HTTP::redirect https://[getfield [HTTP::host] ":" 1][HTTP::uri]
}
elseif { [TCP::local_port] eq 443 && [string tolower [HTTP::uri]] eq "/articles/2015/09/09/something.aspx" } {
HTTP::redirect http://[getfield [HTTP::host] ":" 1][HTTP::uri]
}
else {
HTTP::redirect https://[HTTP::host][HTTP::uri]
}
}
Brad_Parker_139
Oct 06, 2015Nacreous
with the else removed it loops?