php - Curl cookie handling -


Is it possible that not every user can use the same cookie?

Because it is good that I store the cookies I get, but this cookie will be used by everyone, and this should be because it is a login cookie.

Charlie

  1. the client makes a request

  2. "Post-Text" itemprop = "text">

  3. The server sees the request and asks "Hey, does this client send me a cookie?"

  4. The server cookie does not appear, so it sends a response with some stuff, and then the cookie

  5. the client ( Browser) sees the response and says, "Look, a cookie for me, I save it better"

  6. The client next request the same server, She sends the same cookie

  7. The server sees the request and asks "Hey, does this customer send me a cookie?"

  8. The server sees the cookie at this time, and does a few different things about what's in the cookie, and then sends a response with the cookie

  9. The client sees the response and says "Look, a cookie for me, lets me update one"

It seems that in the problem you are running, you have multiple curl requests running from the same machine, but you want everyone to have a Use the look cookie file.

You should be able to get it using the following two curl options

  CURLOPT_COOKIEJAR // says that the file to save the cookie from the server to CURLOPT_COOKIEFILE // Which looks for the file and sends the request as a cookie  

If you set up a system, each different curl request is being set up for these two options, the different path values , You should be set.


Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

php - Multiple Select with Explode: only returns the word "Array" -

php - jQuery AJAX Post not working -