hirox_127495
Aug 02, 2010Historic F5 Account
How do I drop packet from iRules?
Hello,
I created following iRule to enforce connection/second. This iRule supposes to drop client request when LTM get more than 5 connections per second. But actual behavior of 10.2 was send RST back to the client in my verification.
How do I modify this iRule to work as I expected?
---------------------------------------
when CLIENT_ACCEPTED {
set reqno [table incr "reqs"]
table set -subtable "reqrate" $reqno "ignored" indefinite 1
set ConRate [table keys -count -subtable "reqrate"]
if { $ConRate > 5 } {
drop
event disable
return
}
}
---------------------------------------
Thanks!