aboutsummaryrefslogtreecommitdiff
path: root/lib/cookie.c
AgeCommit message (Collapse)Author
2004-02-26use calloc instead of malloc and we won't have to memset() the structDaniel Stenberg
2004-02-26Clear up int/long/size_t/ssize_t usage a bitDaniel Stenberg
2004-01-29Dan Fandrich's cleanup patch to make pedantic compiler options cause lessDaniel Stenberg
warnings. Minor edits by me.
2004-01-07updated year in the copyright stringDaniel Stenberg
2003-08-11Added some infof() calls, that require the data pointer so now severalDaniel Stenberg
cookie functions need that. I also fixed the cookie loader to properly load and deal with cookies without contents (or rather with a blank content).
2003-08-04 Jan Sundin reported a case where curl ignored a cookie that browsers don't,Daniel Stenberg
which turned up to be due to the number of dots in the 'domain'. I've now made curl follow the the original netscape cookie spec less strict on that part.
2003-06-26use CURLDEBUG instead of MALLOCDEBUGDaniel Stenberg
2003-05-15Skip any preceeding dots from the domain name of cookies when we keep themDaniel Stenberg
in memory, only add it when we save the cookie. This makes all tailmatching and domain string matching internally a lot easier. This was also the reason for a remaining bug I introduced in my overhaul.
2003-04-30Many cookie fixes:Daniel Stenberg
o Save domains in jars like Mozilla does. It means all domains set in Set-Cookie: headers are dot-prefixed. o Save and use the 'tailmatch' field in the Mozilla/Netscape cookie jars (the second column). o Reject cookies using illegal domains in the Set-Cookie: line. Concerns both domains with too few dots or domains that are outside the currently operating server host's domain. o Set the path part by default to the one used in the request, if none was set in the Set-Cookie line.
2003-03-31testing, ignore this commitSterling Hughes
2003-01-29removed the local variables for emacs and vim, use the new sample.emacsDaniel Stenberg
way for emacs, and vim users should provide a similar non-polluting style
2003-01-16copyright year update in the source headerDaniel Stenberg
2002-10-28kromJx@crosswinds.net's fix that now uses checkprefix() instead ofDaniel Stenberg
strnequal() when the third argument was strlen(first argument) anyway. This makes it less prone to errors. (Slightly edited by me)
2002-09-03updated source code boilerplate/headerDaniel Stenberg
2002-07-29properly skip white spaces on Set-Cookie: header linesDaniel Stenberg
2002-06-11added disable-[protocol] support, largely provided by Miklos NemethDaniel Stenberg
2002-05-07support for ingoring session cookies addedDaniel Stenberg
2002-04-14Dirk Manske made libcurl strip off white spaces from the beginning of cookieDaniel Stenberg
contents.
2002-03-25Jacky Lam cookie parser fix for domains with preceeding dotDaniel Stenberg
2002-03-19copyright string (year) updateDaniel Stenberg
2002-02-27made Max-Age work as defined in the RFC.Daniel Stenberg
my brain damaged fix to not parse spaces as part of the value is now fixed to instead strip off trailing spaces from values.
2002-02-26When saving a cookie jar, set field 1 (counted from 0) properly to TRUE if theDaniel Stenberg
domain starts with a dot.
2002-02-26removed crash on weird input, this also better discards silly inputDaniel Stenberg
2002-01-07As identified in bug report #495290, the last "name=value" pair in aDaniel Stenberg
Set-Cookie: line was ignored if they didn't end with a trailing semicolon. This is indeed wrong syntax, but there are high-profile web sites out there sending cookies like that so we must make a best-effort to parse them.
2002-01-07added precautions to not go insane when two matching cookies end up in theDaniel Stenberg
cookie list, even though they're not supposed to do that...
2001-10-30prevent strdup()ing NULL -- Paul Harrington's reportDaniel Stenberg
2001-10-24T. Bharath found this memory leak. It occurs when we replace an internallyDaniel Stenberg
already existing cookie with a new one.
2001-10-11looks nicer and is better compatible with older vim versionsSterling Hughes
2001-10-10cookiejar now enables the cookie engineDaniel Stenberg
2001-10-08corrected cookie-jar commentDaniel Stenberg
2001-09-26Now we're setting a default domain for received cookies so that we canDaniel Stenberg
properly match those cookies in subsequent requests
2001-09-10Curl_cookie_output() must check that there's a cookie struct present beforeDaniel Stenberg
trying to address it!
2001-09-07Added formatting sections for emacs and vimSterling Hughes
2001-08-29cookie jar adjustmentsDaniel Stenberg
2001-08-26improved the testDaniel Stenberg
2001-08-23started working on a function for writing (all) cookies, made it possibleDaniel Stenberg
to read multiple cookie files, no longer writes to the URL string passed to the _add() function. The new stuff is now conditionally compiled on the COOKIE define. Changed the _init() proto.
2001-08-14commented out empty else blocks to shut up pedantic compilersDaniel Stenberg
2001-05-30include strtok.h to get the prototypeDaniel Stenberg
2001-05-29strtok() replaced with strtok_r()Daniel Stenberg
2001-05-23Added Andres' comments about field 2 in netscape cookie filesDaniel Stenberg
2001-05-23Andrés García's netscape cookie file parser fixDaniel Stenberg
2001-01-05Internal symbols that aren't static are now prefixed with 'Curl_'Daniel Stenberg
2001-01-03dual-license fixDaniel Stenberg
2000-11-10Venkataramana Mokkapati corrected a cookie parser bugDaniel Stenberg
2000-10-09added memory debugging include fileDaniel Stenberg
2000-09-25a single cookie does not require a trailing semicolon anymoreDaniel Stenberg
2000-08-24#include "setup.h" moved first of all includesDaniel Stenberg
2000-05-22moved here from the newlib branchDaniel Stenberg
2000-02-10* Made '-' as file name to read cookies from equal stdin.Daniel Stenberg
* I hope I finally removed 'empty cookies' crash
2000-02-01Added some RFC2109 supportDaniel Stenberg