cURL / Mailing Lists / curl-users / Single Mail

curl-users

RE: cURL usage dilemma

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 1 May 2002 13:06:40 +0200 (MET DST)

On Tue, 30 Apr 2002, Roth, Kevin P. wrote:

> The -b and -c options don't need to be used together. They both "turn on"
> the cookie engine. -b and -D are the two normally used in combination.
> Here's the skinny:
>
> -D dumps headers (including cookies) into a text file
> -b reads cookies from a text (such as the output from -D)
> and "enables" the cookie parsing engine
>
> -c reads and *writes* cookies from a netscape-style
> cookies file, and "enables" the cookie parsing engine

Actually, -c doesn't _read_ cookies. It only writes them. -b understands both
header-style and cookiejar-style input files. That's why "-b file -c file"
actually makes a pretty good combination in many cases.

> [Daniel -- did we ever create a way to place persistant and non-persistant
> cookies into two different files?]

No. The so called "session" cookies will be stored in the cookie jar when -c
is used, in the same way all other cookies are stored. As curl is often used
with multiple invokes to simulate a single session, it made most sense (to
me).

I think we could instead consider adding an option that prevents such cookies
from being read/used from a given input.

-- 
    Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/
Received on 2002-05-01