Forum Discussion
CraigMo
Nimbostratus
Dec 16, 2014conditional stream irule
Currently the following irule is successful for some of the applications but breaks others:
when HTTP_REQUEST {
Disable the stream filter for client requests
STREAM::disable
Disable comp...
Michael_Jenkins
Cirrostratus
Dec 16, 2014Try this. It should help out. Can't test it at the moment to verify, but I think it'll work.
when HTTP_REQUEST {
Disable the stream filter for client requests
STREAM::disable
Disable compression
HTTP::header remove "Accept-Encoding"
set variables here because you can't access these in HTTP_RESPONSE
set hostLower [string tolower [HTTP::host]]
set pathLower [string tolower [HTTP::path]]
The PATH is the URI without the query string part
}
when HTTP_RESPONSE {
if { ($hostLower contains "connect-q.abbvie.net") && ($pathLower contains "/lstsetng.aspx")} {
Enable the stream filter for text responses only
if {[HTTP::header value Content-Type] contains "text"}{
Replace 'old_text' with 'new_text'
STREAM::expression {@[Hh][[Tt][Tt]Pp(/|&.x2f;){2}@}
Enable the stream filter for this response only
STREAM::enable
}
}
}
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