Forum Discussion
nitass
May 27, 2014Employee
it seems reject does not work with HTTP::respond in HTTP_REQUEST (when request matches both reject and HTTP::respond). not sure if it is a bug or not.
can you move reject to CLIENT_ACCEPTED instead?
this is my testing in 11.5.1.
config
root@(ve11a)(cfg-sync In Sync)(Active)(/Common)(tmos) list ltm virtual bar
ltm virtual bar {
destination 172.28.24.10:80
ip-protocol tcp
mask 255.255.255.255
pool foo
profiles {
http { }
tcp { }
}
rules {
qux
}
source 0.0.0.0/0
source-address-translation {
type automap
}
vs-index 33
}
root@(ve11a)(cfg-sync In Sync)(Active)(/Common)(tmos) list ltm rule qux
ltm rule qux {
when HTTP_REQUEST {
reject
HTTP::respond 301
}
}
test
[root@centos1 ~] curl -I http://172.28.24.10/
HTTP/1.0 301 Moved Permanently
Server: BigIP
Connection: Keep-Alive
Content-Length: 0