summaryrefslogtreecommitdiffstats
path: root/net/base/cookie_monster.h
Commit message (Collapse)AuthorAgeFilesLines
* More cleanup relating to the domain now being part of the CanonicalCookie:rdsmith@chromium.org2010-08-061-5/+2
| | | | | | | | | | | | * Simplify DeleteCookie(CanonicalCookie) API * Get rid of KeyedCanonicalCookie type; not needed. BUG=8850 TEST=Try bots, net_unittest --gtest_filter=CookieMonsterTest.* (refactor, so tests should all keep passing.) Review URL: http://codereview.chromium.org/3095002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55241 0039d316-1c4b-4281-b951-d872f2087c98
* More FRIEND_TEST_ALL_PREFIXES.phajdan.jr@chromium.org2010-07-301-3/+5
| | | | | | | | | TEST=none BUG=44549 Review URL: http://codereview.chromium.org/3053024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@54388 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes targeting the unique creation times invariant in the CookieMonster:rdsmith@google.com2010-07-281-12/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Make sure we don't import cookies with identical creation times. * DCHECK that duplicate cookie list insertion succeeds (it silently didn't when there were not unique creation times.) * Confirm that we eliminate all the duplicats we find on cookie import. * Make Methods allowing setting of creation time private. * Create performance test for import (involved refactoring backing store mock.) This change does increase the performance cost on import, and hence adds to startup time. However, the increase for importing 15000 cookies was only 5 ms, so I think that's acceptable to prevent crashes. rdsmith-macbookpro:~/tmp $ perfparse base_perf_import.txt new_perf_import.txt base_perf_import.txt new_perf_import.txt CookieMonsterTest.TestImport Cookie_monster_import_from_store 26.36 +/- 0.88 31.38 +/- 1.1 BUG=43188 TEST=net_unittest --gtest_filter=CookieMonsterTest.* (including two new tests.), Linux & Windows Review URL: http://codereview.chromium.org/3070001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53957 0039d316-1c4b-4281-b951-d872f2087c98
* `#pragma once` for app, base, chrome, gfx, ipc, net, skia, viewsthakis@chromium.org2010-07-261-0/+1
| | | | | | | | | BUG=50273 TEST=everything still builds, build is 10% faster on windows, same speed on mac/linux TBR: erg git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53716 0039d316-1c4b-4281-b951-d872f2087c98
* Internal CookieMonster Refactoring.rdsmith@google.com2010-07-221-10/+2
| | | | | | | | | | | | | | | | | There are two classes of refactoring in this submission: * Enabled by moving domain->CanonicalCookie. This is mostly just eliminating domain from various argument lists. * Combination of code that will make the next CL easier. This is rewriting GetAllCookiesForURL in terms of FindCookiesForHostAndDomain and nuking FindRawCookies; it'll allow me to change the basic algorithm for probing the cookie map in a single place. BUG=8850 TEST=Linux, net_unittests --gtest_filter=CookieMonsterTest.*:ParsedCookieTest.* Review URL: http://codereview.chromium.org/2904006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53341 0039d316-1c4b-4281-b951-d872f2087c98
* Changed type CookieList to being a vector CanonicalCookies.rdsmith@google.com2010-07-211-6/+4
| | | | | | | | | | | Originally, it was a vector of pair<domain_string, CanonicalCookie>. TEST=Refactor; all relevant unit tests should still pass. BUG=8850 Review URL: http://codereview.chromium.org/2799057 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53184 0039d316-1c4b-4281-b951-d872f2087c98
* Break out histogram counter variables as CookieMonster instance variables.rdsmith@google.com2010-07-201-0/+14
| | | | | | | | | | | | This avoids racing on the initialization of the statics usually declared when doing histogram accumulation. BUG=49142 TEST=net_unittests --gtest_filter=CookieMonsterTest.*:ParsedCookieTest.* (to confirm I didn't break anyting; this doesn't reproduce the race.) Review URL: http://codereview.chromium.org/2832061 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53042 0039d316-1c4b-4281-b951-d872f2087c98
* Converted CanonicalCookies over to containing a domain.rdsmith@google.com2010-07-141-7/+27
| | | | | | | | | | | Added perftest for getters in nested subdomains. BUG=8850 TEST=[Linux] net_unittests --gtest_filter=CookieMonsterTest.*:ParsedCookieTest.*, net_perftests --gtest_filter=CookieMonsterTest.* Review URL: http://codereview.chromium.org/2847046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52350 0039d316-1c4b-4281-b951-d872f2087c98
* Fix incorrect style for CL http://codereview.chromium.org/2718011/showrdsmith@google.com2010-07-071-7/+9
| | | | | | | | | | | identified by Darin after commit. BUG=none TEST=net_unittests --gtest_filter=CookieMonsterTest.*:ParsedCookieTest.* Review URL: http://codereview.chromium.org/2844043 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51768 0039d316-1c4b-4281-b951-d872f2087c98
* Fix bug in DeleteAllForURL; deletes entire store instead of justrdsmith@google.com2010-07-071-2/+5
| | | | | | | | | | | | | | | cookies related to URL (found by inspection.) Also changed name and semantics to more closely reflect usage of primary caller (extension data deleter), and added test for that set of semantics. BUG=none TEST=Linux CookieMonsterTest.*:ParsedCookieTest.* (especially new CookieMonsterTest.DeleteAllHost) Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=51544 Review URL: http://codereview.chromium.org/2857029 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51766 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 51544 - I think the chances are noticeably above zero that thisrdsmith@google.com2010-07-021-5/+2
| | | | | | | | | | | | | | | | | | | | | | change is responsible for the XP tests (dbg)(4) browser_tests going red, and we're heading into a long weekend. I'll revert, and resubmit next week if it turns out that it wasn't my problem. Original description: Fix bug in DeleteAllForURL; deletes entire store instead of just cookies related to URL (found by inspection.) Also changed name and semantics to more closely reflect usage of primary caller (extension data deleter), and added test for that set of semantics. BUG=none TEST=Linux CookieMonsterTest.*:ParsedCookieTest.* (especially new CookieMonsterTest.DeleteAllHost) Review URL: http://codereview.chromium.org/2857029 TBR=rdsmith@google.com Review URL: http://codereview.chromium.org/2858046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51567 0039d316-1c4b-4281-b951-d872f2087c98
* Fix bug in DeleteAllForURL; deletes entire store instead of justrdsmith@google.com2010-07-021-2/+5
| | | | | | | | | | | | | cookies related to URL (found by inspection.) Also changed name and semantics to more closely reflect usage of primary caller (extension data deleter), and added test for that set of semantics. BUG=none TEST=Linux CookieMonsterTest.*:ParsedCookieTest.* (especially new CookieMonsterTest.DeleteAllHost) Review URL: http://codereview.chromium.org/2857029 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51544 0039d316-1c4b-4281-b951-d872f2087c98
* Initial commit of CookieMonster statistics.rdsmith@google.com2010-06-221-2/+24
| | | | | | | | | | | | | | | | | Specifically: * Number of cookies, recorded every ten minutes of active browsing (i.e. cookies being requested from CookieMonster) * Last access time, recorded when cookie accessed. * Last access time for evicted cookies, recorded on eviction * Time until cookie expires, recorded on insertion. * Reason for a cookie being removed from store, recorded when removed. * Size of batch update to persistent cookie store and whether it succeeded or failed, recorded at success/failure. BUG=4005 TEST=net_unittests CookieMonster.* on Linux Review URL: http://codereview.chromium.org/2718011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50477 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 50296 (Causes DCHECK failures) - Make CookieMonster NonThreadSafe.willchan@chromium.org2010-06-211-10/+2
| | | | | | | | | | | | | Made ExtensionFunction RefCountedThreadSafe so it can be posted to different threads. Used WaitableEvent in AutomationProvider. BUG=44083 Review URL: http://codereview.chromium.org/2756003 TBR=willchan@chromium.org Review URL: http://codereview.chromium.org/2860012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50357 0039d316-1c4b-4281-b951-d872f2087c98
* Make CookieMonster NonThreadSafe.willchan@chromium.org2010-06-181-2/+10
| | | | | | | | | | Made ExtensionFunction RefCountedThreadSafe so it can be posted to different threads. Used WaitableEvent in AutomationProvider. BUG=44083 Review URL: http://codereview.chromium.org/2756003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50296 0039d316-1c4b-4281-b951-d872f2087c98
* Assert SetCookieableScheme called before first use.rdsmith@google.com2010-06-171-0/+2
| | | | | | | | | BUG=44476 TEST=Linux CookieMonster.SetCookieableSchemes (as modified) Review URL: http://codereview.chromium.org/2869002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50105 0039d316-1c4b-4281-b951-d872f2087c98
* Modifies CookieMonster to ease support for the Chrome Extensions cookies API.cindylau@google.com2010-04-301-1/+67
| | | | | | | | | | | | Refactors/extracts some methods for reuse in setting cookies programatically, and in parsing cookie attribute tokens and values. BUG=38398 TEST=none Review URL: http://codereview.chromium.org/1566052 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46135 0039d316-1c4b-4281-b951-d872f2087c98
* Reland r42467. Clear cookies, local storage and databases when an extension ↵jochen@chromium.org2010-03-251-0/+7
| | | | | | | | | | | | gets uninstalled. BUG=27938,39177 TEST=Unittest in extension_service_unitttest.cc Review URL: http://codereview.chromium.org/1257005 Patch from Mattias Nissler. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42611 0039d316-1c4b-4281-b951-d872f2087c98
* Reland r42473. Add a delegate to CookieMonster and broadcast notifications ↵jochen@chromium.org2010-03-251-67/+88
| | | | | | | | | | | | | | about changes to cookies. This change will allow implementing the experimental cookie extension API, specifically the cookies.onChaned event BUG=none TEST=net_unittests TBR=jochen@ Review URL: http://codereview.chromium.org/1287001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42586 0039d316-1c4b-4281-b951-d872f2087c98
* Reverts 42520 and 42477. It back red again when adding this change back.maruel@chromium.org2010-03-251-7/+0
| | | | | | | | | | TEST=valgrind test: unit should turn green BUG=38398 BUG=39177 Review URL: http://codereview.chromium.org/1313003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42569 0039d316-1c4b-4281-b951-d872f2087c98
* Reapply 42467 by reverting 42499 and added suppression.maruel@chromium.org2010-03-241-0/+7
| | | | | | | | | | | "Clear cookies, local storage and databases when an extension gets uninstalled." BUG=39177 BUG=38398 Review URL: http://codereview.chromium.org/1210004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42520 0039d316-1c4b-4281-b951-d872f2087c98
* Revert r42467: "Clear cookies, local storage and databases when an extension ↵maruel@chromium.org2010-03-241-7/+0
| | | | | | | | | | | | gets uninstalled." It introduced a memory leak, causing a regression on valgrind test: unit. TBR=jochen Review URL: http://codereview.chromium.org/1295001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42499 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 42473 - Add a delegate to CookieMonster and broadcast notifications ↵dhollowa@chromium.org2010-03-241-88/+67
| | | | | | | | | | | | | | | | about changes to cookies. This change will allow implementing the experimental cookie extension API, specifically the cookies.onChanged event BUG=38398 TEST=net_unittests Review URL: http://codereview.chromium.org/1023004 TBR=jochen@chromium.org Review URL: http://codereview.chromium.org/1256003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42478 0039d316-1c4b-4281-b951-d872f2087c98
* Add a delegate to CookieMonster and broadcast notifications about changes to ↵jochen@chromium.org2010-03-241-67/+88
| | | | | | | | | | | | | cookies. This change will allow implementing the experimental cookie extension API, specifically the cookies.onChanged event BUG=38398 TEST=net_unittests Review URL: http://codereview.chromium.org/1023004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42473 0039d316-1c4b-4281-b951-d872f2087c98
* Clear cookies, local storage and databases when an extension gets uninstalled.jochen@chromium.org2010-03-241-0/+7
| | | | | | | | | | BUG=27938 TEST=Unittest in extension_service_unitttest.cc Review URL: http://codereview.chromium.org/1095003 Patch from Mattias Nissler. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42467 0039d316-1c4b-4281-b951-d872f2087c98
* Avoid showing the user a garbage path attribute when the cookie doesn't have andarin@chromium.org2010-02-121-1/+2
| | | | | | | | | | | | | | | | explicit path set. This CL also ensures that we set the expiry info properly. This means using CanonPath and CanonExpiration from cookie_monster.cc. Instead of exposing those methods, I just expose a CanonicalCookie constructor that takes a ParsedCookie. R=pkasting BUG=none TEST=none Review URL: http://codereview.chromium.org/597031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38984 0039d316-1c4b-4281-b951-d872f2087c98
* Recover from inconsistent cookie database.eroman@chromium.org2010-02-121-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In particular, if the database has multiple cookies defined for the same (host, cookie name, cookie path), we will delete all but the most recently created cookie. This step happens right after loading the cookie database. I don't expect this to have any real impact on startup performance, since the cookie database is small, and compared to the cost of reading the DB from disk, should be cheap. This CL also includes two other related changes: (1) Added a histogram "Net.NumDuplicateCookiesInDb" that measures how common the need to remove duplicates is. (2) If the in-memory store is ever found to contain duplicates after initializion, fail hard (crash). The effect of this change will be users that had a bad database will get it fixed, and will no longer be sending duplicate cookies to servers. ----------------------- Background: ----------------------- Ok, so why does the corruption happen in the first place? From what I can tell, the problem stems from how the interface between CookieMonster and the PersistentCookieStore is defined. Notably: * It implements overwrites as "delete" + "insert" operations. * It doesn't define the behavior when a "delete" or "insert" operation fails. The steps that CookieMonster() runs through to overwrite a cookie is: (a) Find the existing cookie, |old_cookie|, in the in-memory store. (b) Delete |old_cookie| from the in-memory store. (c) Ask the persistent cookie backing store to delete |old_cookie| (keyed by its creation time) (d) Insert |new_cookie| into the in-memory store. (e) Ask the persistent backing store to insert |new_cookie|. This ordering assumes that no failures can happen during steps (c) and (e). However in actuality, SQLitePersistentCookieStore swallows any errors it encounters writing to the DB, and does not attempt retries. Here is one sequence of steps that could lead to your database getting hosed: (1) Your cookie database becomes temporarily unwritable (maybe your home directory is network mounted and your kerberose ticket just expired). (2) The browser gets a set-cookie to overwrite an existing cookie (perhaps a ping-back from gmail, which happen often). Clearly steps (c) and (e) will now fail, since the database is offline. So the in-memory store will get changed, but the on-disk one won't. (3) Now your cookie database becomes writable again (maybe you renewed the ticket). (4) Another cookie update is received. This time, the update will cause us to insert a duplicate into the cookie database. This happens because in step (c) the on-disk database is asked to delete the previous (at least according to the in-memory store) cookie. Well, the on-disk DB never wrote that value, so this has no effect, and the actual previous value remains. Next we insert the new value, kaboom. A next step will be to re-work the PersistentCookieStore interface so SQLitePersistentCookieStore isn't as fragile to errors while overwriting. BUG=17855 TEST=CookieMonsterTest.DontImportDuplicateCookies Review URL: http://codereview.chromium.org/602029 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38880 0039d316-1c4b-4281-b951-d872f2087c98
* Revert the revert... This has the cumulative effect of relanding 38694.eroman@chromium.org2010-02-111-7/+5
| | | | | | | | | | | | | | | | The chrome frame failure appears to be unrelated. Add some tests to CookieMonster for overwriting persistent cookies, and checking that the PersistentCookieStore interface is exercised correctly. Review URL: http://codereview.chromium.org/600040 TBR=eroman@chromium.org Review URL: http://codereview.chromium.org/596048 TBR=eroman@chromium.org Review URL: http://codereview.chromium.org/604012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38728 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 38694 - For some reason this seems to be hanging chrome frame tests, ↵eroman@chromium.org2010-02-101-5/+7
| | | | | | | | | | | | | even though this should be a strictly no-op change... Add some tests to CookieMonster for overwriting persistent cookies, and checking that the PersistentCookieStore interface is exercised correctly. Review URL: http://codereview.chromium.org/600040 TBR=eroman@chromium.org Review URL: http://codereview.chromium.org/596048 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38707 0039d316-1c4b-4281-b951-d872f2087c98
* Add some tests to CookieMonster for overwriting persistent cookies, and ↵eroman@chromium.org2010-02-101-7/+5
| | | | | | | | checking that the PersistentCookieStore interface is exercised correctly. Review URL: http://codereview.chromium.org/600040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38694 0039d316-1c4b-4281-b951-d872f2087c98
* Add path filtering into the GetAllCookiesForURL.pfeldman@chromium.org2010-02-041-2/+3
| | | | | | Review URL: http://codereview.chromium.org/573011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38112 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 38001 and 38002.darin@chromium.org2010-02-031-19/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Modify CookiePolicy to work asynchronously This change will enable us to prompt the user before setting a cookie. While we only need to prompt before setting, we actually need to make both CanSetCookie and CanGetCookies asynchronous. This is necessary in order to preserve FIFO ordering since the value returned by GetCookies depends on the changes made to the cookie DB by SetCookie. This change also includes some simplification of CookieStore. Instead of N virtual functions, I distilled it down to only 4. The remaining functions are instead expressed in terms of those. While studying all the places where we currently use CookiePolicy, I found that some of them were not appropriate. After discussing with Amit, I decided to remove the policy checks in URLRequestAutomationJob. See the comments in the code regarding this. I changed the signature of CookieMonster::GetRawCookies to GetAllCookiesForURL to better match GetAllCookies. Related to this change webkit/glue/webcookie.h grows a constructor that takes a CanonicalCookie to help clean up some code. On the Chrome side, ChromeURLRequestContext now has a ChromeCookiePolicy object. That object is threadsafe ref counted because it is passed between the UI and IO threads. It is responsible for implementing the queuing logic described above. It will also in the future trigger the Chrome UI code to actually show the setcookie prompt. Please review the state machinery changes in URLRequestHttpJob carefully. R=eroman BUG=34331 TEST=no tests yet for prompting. Review URL: http://codereview.chromium.org/564045 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38028 0039d316-1c4b-4281-b951-d872f2087c98
* Back out trunk r37998.mark@chromium.org2010-02-031-14/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | Modify CookiePolicy to work asynchronously This change will enable us to prompt the user before setting a cookie. While we only need to prompt before setting, we actually need to make both CanSetCookie and CanGetCookies asynchronous. This is necessary in order to preserve FIFO ordering since the value returned by GetCookies depends on the changes made to the cookie DB by SetCookie. This change also includes some simplification of CookieStore. Instead of N virtual functions, I distilled it down to only 4. The remaining functions are instead expressed in terms of those. While studying all the places where we currently use CookiePolicy, I found that some of them were not appropriate. After discussing with Amit, I decided to remove the policy checks in URLRequestAutomationJob. See the comments in the code regarding this. I changed the signature of CookieMonster::GetRawCookies to GetAllCookiesForURL to better match GetAllCookies. I also filed a bug about making it even closer in functionality. Related to this change webkit/glue/webcookie.h grows a constructor that takes a CanonicalCookie to help clean up some code. On the Chrome side, ChromeURLRequestContext now has a ChromeCookiePolicy object. That object is threadsafe ref counted because it is passed between the UI and IO threads. It is responsible for implementing the queuing logic described above. It will also in the future trigger the Chrome UI code to actually show the setcookie prompt. Please review the state machinery changes in URLRequestHttpJob carefully. R=eroman BUG=34331 TEST=no tests yet for prompting. Review URL: http://codereview.chromium.org/567015 TBR=darin@chromium.org Review URL: http://codereview.chromium.org/562037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38002 0039d316-1c4b-4281-b951-d872f2087c98
* Modify CookiePolicy to work asynchronouslydarin@chromium.org2010-02-031-19/+14
| | | | | | | | | | | | | | | | | | | | | This change will enable us to prompt the user before setting a cookie. While we only need to prompt before setting, we actually need to make both CanSetCookie and CanGetCookies asynchronous. This is necessary in order to preserve FIFO ordering since the value returned by GetCookies depends on the changes made to the cookie DB by SetCookie. This change also includes some simplification of CookieStore. Instead of N virtual functions, I distilled it down to only 4. The remaining functions are instead expressed in terms of those. While studying all the places where we currently use CookiePolicy, I found that some of them were not appropriate. After discussing with Amit, I decided to remove the policy checks in URLRequestAutomationJob. See the comments in the code regarding this. I changed the signature of CookieMonster::GetRawCookies to GetAllCookiesForURL to better match GetAllCookies. I also filed a bug about making it even closer in functionality. Related to this change webkit/glue/webcookie.h grows a constructor that takes a CanonicalCookie to help clean up some code. On the Chrome side, ChromeURLRequestContext now has a ChromeCookiePolicy object. That object is thread-safe ref counted because it is passed between the UI and IO threads. It is responsible for implementing the queuing logic described above. It will also in the future trigger the Chrome UI code to actually show the set-cookie prompt. Please review the state machinery changes in URLRequestHttpJob carefully. R=eroman BUG=34331 TEST=no tests yet for prompting. Review URL: http://codereview.chromium.org/567015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37998 0039d316-1c4b-4281-b951-d872f2087c98
* DevTools: CookieMonster::GetRawCookies should return keys as well as cookies.pfeldman@chromium.org2010-02-031-3/+10
| | | | | | Review URL: http://codereview.chromium.org/565035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37978 0039d316-1c4b-4281-b951-d872f2087c98
* Modified cookie alert prompt window to suport displaying of local storage ↵pkasting@chromium.org2010-02-021-9/+1
| | | | | | | | | | | | info as well. Original patch by Zelidrag Hornung, r=me, tweaked. BUG=32719 TEST=none Review URL: http://codereview.chromium.org/563007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37818 0039d316-1c4b-4281-b951-d872f2087c98
* Second patch in making destructors of refcounted objects private.jam@chromium.org2009-11-051-2/+2
| | | | | | | | BUG=26749 Review URL: http://codereview.chromium.org/368001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31165 0039d316-1c4b-4281-b951-d872f2087c98
* DevTools: Implement raw cookies access for inspector.pfeldman@chromium.org2009-10-291-0/+3
| | | | | | Review URL: http://codereview.chromium.org/294025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30457 0039d316-1c4b-4281-b951-d872f2087c98
* Change update threshold in CookieMonster for testing from 1s to 20ms to ↵vandebo@chromium.org2009-10-281-3/+3
| | | | | | | | | | | speedup test. BUG=24687 TEST=unit tests still pass Review URL: http://codereview.chromium.org/345012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30385 0039d316-1c4b-4281-b951-d872f2087c98
* This CL changes the CookieStore obect to be a refcounted object to get a ↵ananta@chromium.org2009-09-051-2/+6
| | | | | | | | | | | | better handle on its lifetime as there are cases where this object is handed out to URLRequestContext instances which outlive the URLRequestContext object which created it. Partial fix for http://code.google.com/p/chromium/issues/detail?id=15289 Bug=15289 Review URL: http://codereview.chromium.org/197023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25558 0039d316-1c4b-4281-b951-d872f2087c98
* Navigation and cookies for Automationamit@chromium.org2009-07-281-41/+27
| | | | | | | | | | | | | Give Automation better visibility and control over navigations. Also, make it possible for automation to implement a dummy cookie store to go with dummy request serving over automation. BUG=none TEST=none Review URL: http://codereview.chromium.org/159189 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21836 0039d316-1c4b-4281-b951-d872f2087c98
* Reverting 16158.beng@google.com2009-05-151-3/+0
| | | | | | Review URL: http://codereview.chromium.org/113470 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16163 0039d316-1c4b-4281-b951-d872f2087c98
* Privacy option added for all cookies to become session cookies.idanan@chromium.org2009-05-151-0/+3
| | | | | | | BUG=10502 Review URL: http://codereview.chromium.org/87047 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16158 0039d316-1c4b-4281-b951-d872f2087c98
* Add a separate cookie store that's used for extensions.mpcomplete@google.com2009-05-141-0/+13
| | | | | | | Modify CookieMonster to support overriding the "cookieable schemes". Review URL: http://codereview.chromium.org/115204 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16083 0039d316-1c4b-4281-b951-d872f2087c98
* NO CODE CHANGEdeanm@chromium.org2009-03-111-1/+0
| | | | | | | | | Normalize end of file newlines in net/. All files end in a single newline. Review URL: http://codereview.chromium.org/43079 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11442 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes CRLF and trailing white spaces.maruel@chromium.org2009-03-051-1/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
* CookieMonster quote parsing changes and tests.deanm@chromium.org2009-01-091-0/+4
| | | | | | | | | | | | | | | | | This fixes one bug where a cookie like: A="BBB" ; Would be "BBB"; in all other browser, but "BBB" ; in Chrome. Additionally it fixes creating unintentional (but harmless) empty attributes. We had previously tried to match Firefox, but after long discussions we decided it makes more sense to match Internet Explorer and Safari. This means not explicitly handling quoted-string as proposed in the newer RFCs. Before: A="B;C"; -> A="B;C"; After: A="B;C"; -> A="B; Review URL: http://codereview.chromium.org/17045 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7810 0039d316-1c4b-4281-b951-d872f2087c98
* Enforce httponly on cookies coming from the renderer. This prevents ↵deanm@chromium.org2008-11-191-12/+34
| | | | | | | | | javascript from setting a new httponly cookie, and more importantly from overwriting httponly cookies. Patch from Marius Schilder. Review URL: http://codereview.chromium.org/11275 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5700 0039d316-1c4b-4281-b951-d872f2087c98
* Try to fix Mac and Linux compiles.pkasting@chromium.org2008-11-011-1/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4357 0039d316-1c4b-4281-b951-d872f2087c98
* Expire cookies by last access date, rather than creation date.pkasting@chromium.org2008-11-011-5/+28
| | | | | | | BUG=2906 Review URL: http://codereview.chromium.org/8753 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4354 0039d316-1c4b-4281-b951-d872f2087c98