Give this a try:
when HTTP_REQUEST {
HTTP::version 1.0
}
when HTTP_RESPONSE {
HTTP::collect 4294967295
}
when HTTP_RESPONSE_DATA {
set find ":8088"
set replace ""
log local0. "payload: [HTTP::payload]"
if {[regsub -all $find [HTTP::payload] $replace new_response] > 0} {
log local0. "Match found - regsub returned greater than zero!"
log local0. "New Response: $new_response"
HTTP::payload replace 0 [HTTP::payload len] $new_response
} else {
log local0. "No match found - regsub returned zero!"
}
}
All the "log" statements will put the strings into the /var/log/ltm file.
*Note1 : that I removed the $payload variable to avoid an unnecessary copy of the entire payload value.
*Note2 : Make sure you remove the log commands before moving this rule into production.
*Note3 : If you have it available, I would still
highly recommend using the Stream profile for this if you can. It has much less overhead on the system.
-Joe