1 Reply Latest reply on Sep 10, 2008 8:30 AM by Newsgroup_User

    Passing another sites cookie on to the client?

      We are working with a third party vendor who has a web site which our CF server will authenticate to on behalf of the client browser using CFHTTP, and then the third party site replies back to our CF server with a cookie which we need to pass to the client browser. The client can then communicate with the third party site once the client has the cookie. Obviously I can use CFCOOKIE to create the client side cookie but what's the easiest way to read the cookie returned to the CF Server?
        • 1. Re: Passing another sites cookie on to the client?
          Level 7
          I'm not sure this will work? My understanding the nature of cookies is
          that the browser will only return cookies to a domain that where created
          by that domain.

          So, even when you get that cookie and write it to the client (which can
          be done), the browser will only ever return that cookie when the client
          is talking to your server. When they move on to the other server, the
          browser will not send the cookie.

          This may be outdated, but I thought that is how it works.

          I am aware there are some way around this, but I have never bothered to
          learn how to circumvent the methodology. I think it involves frames,
          hidden or otherwise, connected to the remote server. So the browser
          then connects to that server, receives the cookies and sets them for it.