我编写了请求 live.com 的简单 C# 代码
WebRequest request =
HttpWebRequest.Create(new Uri(@"https://login.live.com/login.srf?wa=wsignin1.0&rpsnv=11&ct=1378924108&rver=6.1.6206.0&wp=MBI&wreply=http:%2F%2Fmail.live.com%2Fdefault.aspx&lc=1049&id=64855&mkt=ru-ru&cbcxt=mai&snsc=1"));
((HttpWebRequest) request).CookieContainer=new CookieContainer();
WebResponse response=request.GetResponse();
CookieCollection collection=((HttpWebResponse)response).Cookies;
执行请求后,我看到了一个 cookie
但 Fiddler 表明这是两个 cookie 作为响应。
HTTP/1.1 200 OK
Cache-Control: max-age=0
Content-Length: 12131
Content-Type: text/html; charset=utf-8
Expires: Wed, 11 Sep 2013 19:16:24 GMT
Server: Microsoft-IIS/7.5
P3P: CP="DSP CUR OTPi IND OTRi ONL FIN"
X-XSS-Protection: 0
X-Content-Type-Options: nosniff
Set-Cookie: MSPRequ=lt=1378927044&co=1&id=64855; path=/;HTTPOnly=;version=1
Set-Cookie: MSPOK=$uuid-095618db-a129-4ee7-a760-eb20f9a20d2d; domain=login.live.com;path=/;version=1
X-Frame-Options: deny
PPServer: PPV: 30 H: BAYIDSLGN2G011 V: 0
Date: Wed, 11 Sep 2013 19:17:24 GMT
Connection: close
“MSPOK”cookie 在哪里?我怎样才能得到它?