Curl emulation login found the URL of the cookie is always changed
The first step, get the way to open the first page, the second step, click the Login button on the home page, will come out login box, post data to complete the login.
The second step requires a cookie value that is generated at the first step.
The first step is to access the home page, but will automatically follow the request for nearly 10 URLs. Many of these URLs are the first page loaded JS is sent automatically.
And this cookie is the one page in these pages written to the client.
It's hard to get this cookie to simulate 10 pages?
And found that these pages also have changes, and some URLs will appear in this time, the next time you hit a home page does not appear. In short, it is not known which page the cookie was sent to at the time of the visit.
Does curl seem to be unable to automatically process the new page of the JS request under the first request page like a browser?
If you want to do a page to simulate, it seems unlikely.
I was thinking, using curl to request a page, this page automatically issued a subsequent request, curl should be automatic processing is, so that all cookies can be obtained. But the implementation doesn't seem to be so, curl can only request one URL for a URL.
Is it, like this situation, that curl is powerless? After all, curl is not a browser.
You are prompted to prompt. If curl can't handle it, what words can be achieved? URL Browser
------Solution--------------------
Clear all cookie caches and then browse through this page to grab a packet and see what the URL is. Repeat until you capture the URL that generated the cookie.
Access the destination page of the url+ that generated the cookie.
This is a cumbersome process, curl is not an intelligent robot, he is only a multi-protocol to support the transmission tool.
------Solution--------------------
Does Curl Execute JS?
Those professional browsers have compatibility issues.