diff options
author | Daniel Stenberg <daniel@haxx.se> | 2020-01-10 22:53:05 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2020-01-13 23:18:32 +0100 |
commit | 9d1a0922b7b1eadd0f36167641f78d24a819b62d (patch) | |
tree | 14785bb6ecdbea3f4b2ddb9433fc25786ca953bd /docs/HTTP-COOKIES.md | |
parent | 4ccf7622db04af58442c460b8091b952585de5c7 (diff) | |
download | curl-9d1a0922b7b1eadd0f36167641f78d24a819b62d.tar.gz |
HTTP-COOKIES.md: describe the cookie file format
... and refer to that file from from CURLOPT_COOKIEFILE.3 and
CURLOPT_COOKIELIST.3
Assisted-by: Jay Satiro
Reported-by: bsammon on github
Fixes #4805
Closes #4806
Diffstat (limited to 'docs/HTTP-COOKIES.md')
-rw-r--r-- | docs/HTTP-COOKIES.md | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/docs/HTTP-COOKIES.md b/docs/HTTP-COOKIES.md index 06790f8a7..62367c2a9 100644 --- a/docs/HTTP-COOKIES.md +++ b/docs/HTTP-COOKIES.md @@ -43,6 +43,24 @@ When libcurl saves a cookiejar, it creates a file header of its own in which there is a URL mention that will link to the web version of this document. +## Cookie file format + + The cookie file format is text based and stores one cookie per line. Lines + that start with `#` are treated as comments. + + Each line that each specifies a single cookie consists of seven text fields + separated with TAB characters. + + |Field| Type | Example | Meaning | + |---|---------|-------------|-----------------------------------------------| + | 0 | string | example.com | Domain name | + | 1 | boolean | FALSE | Include subdomains | + | 2 | string | /foobar/ | Path | + | 3 | boolean | TRUE | Send/receive over HTTPS only | + | 4 | number | 1462299217 | Expires at – seconds since Jan 1st 1970, or 0 | + | 5 | string | person | Name of the cookie | + | 6 | string | daniel | Value of the cookie | + ## Cookies with curl the command line tool curl has a full cookie "engine" built in. If you just activate it, you can |