aspose file tools*
The moose likes Sockets and Internet Protocols and the fly likes why i can't get cookie from a special web site? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "why i can Watch "why i can New topic
Author

why i can't get cookie from a special web site?

jieyun liu
Greenhorn

Joined: Oct 08, 2008
Posts: 4



My question is: How can I get the cookie from the web site:http://www.csdn.net?
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

"hea ton", please check your private messages.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
jieyun liu
Greenhorn

Joined: Oct 08, 2008
Posts: 4
Originally posted by Paul Sturrock:
"hea ton", please check your private messages.


i have changed my name, is that right?
Pat Farrell
Rancher

Joined: Aug 11, 2007
Posts: 4637
    
    5

Originally posted by hea ton:
My question is: How can I get the cookie from the web site: http://www.csdn.net?[/b][/QB]


Cookie security rules say that only two places can get to a cookie.

1) the user can get them from his browser
2) a site can get those created for their domain

So the answer is to be on www.csdn.net and get them there
jieyun liu
Greenhorn

Joined: Oct 08, 2008
Posts: 4
hi, Pat. First, Thanks for your help.
But I am still in trouble.
I know where I shoule get the cookie from, But i don't know how.

you refer to the cookie security rules, can you give me some urls of books or references?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39547
    
  27
What do you mean by "the cookie"? That page doesn't set any cookies. It includes various elements that do so (images, iframes etc.) though; if you want to access the cookies set by those, then you'll need to load those elements in addition to the main page.


Ping & DNS - updated with new look and Ping home screen widget
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12678
    
    5
Cookie rules are contained in RFC2965 - a google search will lead you straight to a copy of this standard.
Bill
jieyun liu
Greenhorn

Joined: Oct 08, 2008
Posts: 4
Originally posted by William Brogden:
Cookie rules are contained in RFC2965 - a google search will lead you straight to a copy of this standard.
Bill


One Month ago, I have read the reference.
But I can not find the answer.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39547
    
  27
But I can not find the answer.

If the question is still the original one -how to get a cookie from that page- then I would have thought that my post answers that ... not so?
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12678
    
    5
How did the the cookie from "http://www.csdn.net" get set in the first place?

In what interaction did csdn.net get a request and send a response HTTP header setting a cookie?

What received the response containing the cookie?

Bill
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: why i can't get cookie from a special web site?
 
Similar Threads
Unable to access tomcat protected resource using Cookie manager for JSessionID
Problems connecting to LDAP from Weblogic Server: BAD_CERTIFICATE error!
Invoking webservice- Server returned HTTP response code: 500
Web service using HttpURLConnection
Set cookie for given site