Forum Discussion
John_Barney_102
Nimbostratus
Apr 18, 2005UDP::payload replace
Anyone know if "replace" is supported in UDP::payload?
The documentation does not list it.
If not, does anyone know of a way to manipulate some data (generically) in UDP packets?
- unRuleY_95363Historic F5 AccountYes, UDP::payload supports "replace", same format as for TCP::payload.
- John_Barney_102
Nimbostratus
Thanks! - drteeth_127330Historic F5 AccountThe arguments are the same as for TCP. When do you get the error? What version are you running? The following command works fine for me:
bigpipe rule udp_rule '{ when CLIENT_DATA { UDP::payload replace 0 4 "test" } }'
- John_Barney_102
Nimbostratus
We're running 9.0.4.when CLIENT_DATA { set payload [UDP::payload [UDP::payload length]] set blank “\n” Find the data to replace regsub -all "Replace me\n" $payload $blank new_response Replace the content if there was a match if {$new_response != 0} { UDP::payload replace 0 [UDP::payload length] $new_response } }
- drteeth_127330Historic F5 AccountThe above rule seems to be accepted on 9.0.5. However, I don't recall any fixes for UDP::payload. Check your rule for any trailing or otherwise unexpected whitespace.
- John_Barney_102
Nimbostratus
Upgrading to 9.0.5 solved the problem!
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects