11 #include <curl/curl.h>
14 struct Cookie
*next
; /* next in the chain */
15 char *name
; /* <this> = value */
16 char *value
; /* name = <this> */
17 char *path
; /* path = <this> */
18 char *domain
; /* domain = <this> */
19 time_t expires
; /* expires = <this> */
20 char *expirestr
; /* the plain text version */
21 bool secure
; /* whether the 'secure' keyword was used */
25 /* linked list of cookies we know of */
26 struct Cookie
*cookies
;
28 char *filename
; /* file we read from/write to */
31 /* This is the maximum line length we accept for a cookie line */
32 #define MAX_COOKIE_LINE 2048
33 #define MAX_COOKIE_LINE_TXT "2047"
35 /* This is the maximum length of a cookie name we deal with: */
37 #define MAX_NAME_TXT "255"
39 struct Cookie
*cookie_add(struct CookieInfo
*, bool, char *);
40 struct CookieInfo
*cookie_init(char *);
41 struct Cookie
*cookie_getlist(struct CookieInfo
*, char *, char *, bool);
42 void cookie_freelist(struct Cookie
*);
43 void cookie_cleanup(struct CookieInfo
*);