Internetsetcookieex and Internetgetcookieex use Tip (cookie file format)

Source: Internet
Author: User

Both functions should note that the Szcookiename parameter is not very good, preferably set to NULL, and then write the cookie manually in the content:

"My_cookie_name=my_cookie_value; path=/; expires=wed, 30-mar-11 09:00:00 GMT; Domain=.csdn.net "

Read the whole thing and then parse it yourself.

In addition, the Internetgetcookieex dwflag parameter, for IE8, it is best to add internet_cookie_httponly to read out the COOKIE field value with the HttpOnly attribute. If the SDK is older, without this macro, you can getprocaddress the two functions directly from the DLL, and then define this value for 0x00002000 use. For IE6 and IE7, to get the HttpOnly cookie, you have to manually read the cookie file and parse it.

Cookie file Format:

_ntes_nnid//Field name

456f74e9863f8f4b1a1e37774b0c464d,0//Field value

163.com///field-owned domain

3584//Logo bit

3205176064//Expiration Time (Low)

37425091//Expiration Time (high)

2444768976//creation time (Low)

30082544//Creation time (high)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.