Forum Discussion

Jonas_Karlsson1's avatar
Jonas_Karlsson1
Historic F5 Account
Aug 10, 2005

Cookie insert problem

Hi,

 

 

I'm testing an iRule and have a strange problem (strange for me at least).

 

 

In the HTTP_REQUEST event i insert a cookie and then check that in HTTP_RESPONSE. However, the server never returns the cookie. Am I just confused and stupid or is this the way it works?

 

  • Cookies are client-side entities. Typically the webserver (or an iRule HTTP_RESPONSE) event would set the cookie which would then be sent down to the client's browser. When the next browser connection is made, the cookie is sent back to the webserver (or the iRule HTTP_REQUEST event) via an HTTP request header value.

     

     

    By setting the cookie on the HTTP_REQUEST event, you are basically emulating the browser's caching and sending of the cookie to the webserver. The cookie it not typically returned from the webserver back to the client (unless code was written on the webserver to specifically add that response header.

     

     

    -Joe