cancel
Showing results for 
Search instead for 
Did you mean: 

HTTP Response rewrite

ottleydamian
Cirrus
Cirrus

I trying to modify text in the data portion of a packet but I'm not having success. The content-type does state text as one of the types, I have the default stream profile attached to the VIP. So I'm not sure if my code is incorrect or the F5 cannot read the response. I'm trying to change mywebsite.plate.com to abclabs.facts.net

 

If I should use something other than a stream profile tell me.

 

Client Request:

  • POST /xi/ajax/whatever... HTTP/1.1

 

Server Response:

 

My code:

when HTTP_RESPONSE {   # Check if response type is text   if {[HTTP::header value Content-Type] contains "text"}{        # Replace mywebsite.plate.com with abclabs.facts.net     STREAM::expression "mywebsite.plate.com@abclabs.facts.net@"         # Enable the stream filter for this response only     STREAM::enable      } }

 

1 REPLY 1

ottleydamian
Cirrus
Cirrus

Solved: the example I looked at was wrong, the syntax is

 STREAM::expression {@corning03.plateau.com@kdlabs.corningtest.net@}