Forum Discussion
gamm_31377
Nimbostratus
May 27, 2014HTTP::payload replacement
Hello,
I try to modify a HTTP SOAP request from a client, because the used namespace is
not correct (:i -> :xsi). The iRule is assigned to the virtual server.
The replacement is correct, but when ...
Kevin_Stewart
Employee
May 27, 2014You should actually be able to get away with using a STREAM profile here. It'll be much faster than buffering request payload and you can also get rid of the regex.
when HTTP_REQUEST {
if { [HTTP::header Content-Type] contains "soap" } {
STREAM::expression {@:i@:xsi@}
STREAM::enable
} else {
STREAM::disable
}
}
when HTTP_RESPONSE {
STREAM::disable
}
One important caveat of using STREAM in an HTTP_REQUEST is that you need to force HTTP chunking. Create a new HTTP profile and set Request Chunking to "Rechunk". Add this HTTP profile and a generic empty STREAM profile to the VIP, along with this iRule.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
