forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Cookies and PGWARE's Internet Pack Extension

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
trapper
Contributor
Contributor


Joined: 28 Jan 2005
Posts: 112
Location: Brisbane, Australia

PostPosted: Tue Jul 26, 2005 5:25 am    Post subject: Cookies and PGWARE's Internet Pack Extension Reply with quote

I need to download from a website (HTTP) that requires the use of cookies. As far as I can tell VDSIPP does not support them as I keep getting a page back informing me that my browser doesn't use cookies.

Is this correct or can I enable them somehow?

Cheers.

PS. I realise support is no longer offered for VDSIPP, but I'm just hoping someone will know and prevent me from wasting a lot of time. Thanks.

_________________
John Trappett
Back to top
View user's profile Send private message
PGWARE
Web Host


Joined: 29 Dec 2001
Posts: 1565

PostPosted: Tue Jul 26, 2005 5:49 am    Post subject: Reply with quote

The http portion of the extension does not support cookies. You would have to use the vdsbrowser extension in vds5 or something similar and execute the code; you can hide the browser so it's not visible to users as well.
Back to top
View user's profile Send private message
trapper
Contributor
Contributor


Joined: 28 Jan 2005
Posts: 112
Location: Brisbane, Australia

PostPosted: Tue Jul 26, 2005 6:12 am    Post subject: Reply with quote

That's a shame Sad I was hoping to make use of the THREADS capability of VDSIPP as I had a lot of small pages to download.

Thanks for the quick reply though.

Cheers.

_________________
John Trappett
Back to top
View user's profile Send private message
Skit3000
Admin Team


Joined: 11 May 2002
Posts: 2166
Location: The Netherlands

PostPosted: Tue Jul 26, 2005 7:38 am    Post subject: Reply with quote

Cookies are sent as headers to the server, so if you find a tool which can analyse HTTP calls, you should be able to copy the cookie-header and to use the "internet http,header" command to send the cookie to the server... Smile

vdsipp help file wrote:
INTERNET HTTP,HEADER,<http client>,<string>

This command allows you to add any additional headers into the header of the POST/GET request by specifying it as the <string> parameter.

Normal internet cookies are send like this:

Code:
Set-Cookie: VISIT=1; path=/cgi-bin; expires=Tuesday, 31-Dec-2007 23:12:40 GMT

This is a simple cookie which counts the number of visits you made. This is how you can use it with VDS and the VDSIPP dll:

Code:
internet http, header, 1, "Set-Cookie: VISIT=1; path=/cgi-bin; expires=Tuesday, 31-Dec-2007 23:12:40 GMT"

_________________
[ Add autocomplete functionality to your VDS IDE windows! ]
Voor Nederlandse beginners met VDS: bekijk ook eens deze tutorial!
Back to top
View user's profile Send private message
trapper
Contributor
Contributor


Joined: 28 Jan 2005
Posts: 112
Location: Brisbane, Australia

PostPosted: Tue Jul 26, 2005 8:06 am    Post subject: Reply with quote

Using Wget with the --save-cookie and --load-cookie options I was able to download the required files. This is the cookie info saved by Wget:
Code:
# HTTP cookie file.
# Generated by Wget on 2005-07-26 16:53:24.
# Edit at your own risk.

.www.yourtv.com.au:80   TRUE   /   FALSE   2068430380   TOKEN   C9A8F801511969DB21F5BE6E8AB48B0F
.www.yourtv.com.au:80   TRUE   /   FALSE   2068430380   PERSON_ID   2622468
.www.yourtv.com.au:80   TRUE   /   FALSE   2068436360   CFID   3649592
.www.yourtv.com.au:80   TRUE   /   FALSE   2068436360   CFTOKEN   30960108

Is that of any help in knowing what to send as the header info in a "internet http,header" command?

Cheers.

_________________
John Trappett
Back to top
View user's profile Send private message
Skit3000
Admin Team


Joined: 11 May 2002
Posts: 2166
Location: The Netherlands

PostPosted: Tue Jul 26, 2005 9:27 am    Post subject: Reply with quote

Try something like this Smile

Code:
Set-Cookie: TOKEN=C9A8F801511969DB21F5BE6E8AB48B0F; PERSON_ID=2622468; CFID=3649592; CFTOKEN=30960108; path=/; expires=Tuesday, 31-Dec-2007 23:12:40 GMT

Or this with VDS:
Code:
internet http, header, 1, "Set-Cookie: TOKEN=C9A8F801511969DB21F5BE6E8AB48B0F; PERSON_ID=2622468; CFID=3649592; CFTOKEN=30960108; path=/; expires=Tuesday, 31-Dec-2007 23:12:40 GMT"

_________________
[ Add autocomplete functionality to your VDS IDE windows! ]
Voor Nederlandse beginners met VDS: bekijk ook eens deze tutorial!
Back to top
View user's profile Send private message
trapper
Contributor
Contributor


Joined: 28 Jan 2005
Posts: 112
Location: Brisbane, Australia

PostPosted: Tue Jul 26, 2005 11:06 am    Post subject: Reply with quote

Doesn't seem to work Crying or Very sad

I've just been using the HTTP client example that comes with VDSIPP and using this URL, http://www.yourtv.com.au//guide/index.cfm?checked=true&action=sessionTimes

If you think of anything else or manage to get it working it would be great.

Cheers.

_________________
John Trappett
Back to top
View user's profile Send private message
PGWARE
Web Host


Joined: 29 Dec 2001
Posts: 1565

PostPosted: Tue Jul 26, 2005 2:37 pm    Post subject: Reply with quote

More than likely the site is also setting the cookie, you would have to read the headers to see the contents of the cookie. It may dynamically create a special session id for each user as well.

You could then send back the cookie when it requests one.


I've never tried it so I can't say for 100% certainty.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group