deltapez_21676
Apr 21, 2008Nimbostratus
http to https irule
The following irule was added to redirect any HTTP response from the port 80 web servers to HTTPS. It seems to have a recursion problem and will return an extra "s" (HTTPsS://example.com) in the URL.
when HTTP_RESPONSE {
if { [HTTP::status] == "302" } {
respond with 302 using original Location value
HTTP::respond 302 Location [string map {"http://" "https://"} [HTTP::header Location]]
}
}
In reviewing the captured headers, the following format is intermittently returned:
Location: HTTPsS://example.com
Any suggestions on a better approach that will retain query data, post info, and cookies?