]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
HTTP-COOKIES: clarified and modified layout
authorDaniel Stenberg <daniel@haxx.se>
Tue, 3 Jul 2012 09:10:41 +0000 (11:10 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 3 Jul 2012 09:10:41 +0000 (11:10 +0200)
docs/HTTP-COOKIES

index 4fccb9d9eddc6780473f70c93df4a4f25b02aaf6..818e161eefe1a0f5770ff4785b5d7aa60b63e660 100644 (file)
@@ -8,15 +8,18 @@ Updated: July 3, 2012 (http://curl.haxx.se/docs/http-cookies.html)
 
 HTTP Cookies
 
- 1. Cookie overview
- 2. Cookies saved to disk
- 3. Cookies with curl the command line tool
- 4. Cookies with libcurl
- 5. Cookies with javascript
+ 1. HTTP Cookies
+ 1.1 Cookie overview
+ 1.2 Cookies saved to disk
+ 1.3 Cookies with curl the command line tool
+ 1.4 Cookies with libcurl
+ 1.5 Cookies with javascript
 
 ==============================================================================
 
-1. Cookie overview
+1. HTTP Cookies
+
+  1.1 Cookie overview
 
   HTTP cookies are pieces of 'name=contents' snippets that a server tells the
   client to hold and then the client sends back those the server on subsequent
@@ -36,18 +39,21 @@ HTTP Cookies
   In 2011, RFC6265 (http://www.ietf.org/rfc/rfc6265.txt) was finally published
   and details how cookies work within HTTP.
 
-2. Cookies saved to disk
+  1.2 Cookies saved to disk
 
   Netscape once created a file format for storing cookies on disk so that they
   would survive browser restarts. curl adopted that file format to allow
   sharing the cookies with browsers, only to see browsers move away from that
   format. Modern browsers no longer use it, while curl still does.
 
-  The cookie file format stores one cookie per physical line in the file with
-  a bunch of associated meta data, each field separated with TAB. That file is
-  called the cookiejar in curl terminology.
+  The netscape cookie file format stores one cookie per physical line in the
+  file with a bunch of associated meta data, each field separated with
+  TAB. That file is called the cookiejar in curl terminology.
+
+  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.
 
-3. Cookies with curl the command line tool
+  1.3 Cookies with curl the command line tool
 
   curl has a full cookie "engine" built in. If you just activate it, you can
   have curl receive and send cookies exactly as mandated in the specs.
@@ -70,9 +76,11 @@ HTTP Cookies
     tell curl to start the cookie engine and write cookies to the given file
     after the request(s)
 
-4. Cookies with libcurl
+  1.4 Cookies with libcurl
 
-  libcurl options:
+  libcurl offers several ways to enable and interface the cookie engine. These
+  options are the ones provided by the native API. libcurl bindings may offer
+  access to them using other means.
 
   CURLOPT_COOKIE
 
@@ -101,7 +109,7 @@ HTTP Cookies
     Extract cookie information from the internal cookie storage as a linked
     list.
 
-5. Cookies with javascript
+  1.5 Cookies with javascript
 
   These days a lot of the web is built up by javascript. The webbrowser loads
   complete programs that render the page you see. These javascript programs