Forum Discussion
nitass
May 14, 2015Employee
1) I just ended up with a blank page, which was not
it seems HTTP::host returns null.
configuration
root@(B4200-R77-S7)(cfg-sync Standalone)(Active)(/Common)(tmos) list ltm virtual bar
ltm virtual bar {
destination 200.200.200.114:80
ip-protocol tcp
mask 255.255.255.255
policies {
policy-asm-someapp-uat-3 { }
}
pool foo
profiles {
http { }
tcp { }
websecurity { }
}
security-log-profiles {
"Log illegal requests"
}
source 0.0.0.0/0
source-address-translation {
type automap
}
vs-index 2
}
root@(B4200-R77-S7)(cfg-sync Standalone)(Active)(/Common)(tmos) list ltm policy policy-asm-someapp-uat-3
ltm policy policy-asm-someapp-uat-3 {
controls { asm forwarding }
requires { http }
rules {
default {
actions {
0 {
asm
enable
policy /Common/bar
}
}
ordinal 3
}
poolselect-by-host-value {
actions {
0 {
forward
select
pool foo
}
1 {
asm
enable
policy /Common/bar
}
}
conditions {
0 {
http-host
host
values { someappcaas.uat.somecorp.com someapp.online.ecom.abc }
}
}
ordinal 2
}
redirect-to-home {
actions {
0 {
asm
disable
}
1 {
http-reply
response
redirect
location https://[HTTP::host]/home
}
}
conditions {
0 {
http-uri
values { / }
}
}
ordinal 1
}
}
strategy best-match
}
test
[root@B4200-R77-S7:Active:Standalone] config curl -I http://172.28.24.10/ -H "Host: test.com"
HTTP/1.0 302 Found
Location: https:///home
Server: BigIP
Connection: Keep-Alive
Content-Length: 0
2) if I entered I would get redirected to
i think this one is not redirected by local traffic policies (because you uses equal in policies' condition).