summaryrefslogtreecommitdiffstats
path: root/net/tools
Commit message (Collapse)AuthorAgeFilesLines
* Start migrating the disk cache to using FilePath.tony@chromium.org2009-10-122-3/+5
| | | | | | | | | | This converts BackendImpl to using FilePath. BUG=24444 Review URL: http://codereview.chromium.org/261045 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28711 0039d316-1c4b-4281-b951-d872f2087c98
* Move more ICU-dependent stuff from base into base/i18n. Some test stuff alsobrettw@chromium.org2009-10-091-1/+1
| | | | | | | | | | | | depended on this, so to make the DEPS work out, I made a new base/test directory where I moved the testing-related files into a new directory base/test. TEST=none BUG=none Review URL: http://codereview.chromium.org/266038 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28569 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the UrlToFilenameEncoder to be more cross platform.mbelshe@chromium.org2009-10-071-29/+30
| | | | | | | | | | | | | | | | | FilePath::StringType on linux is a std::string, while on Windows it is a std::wstring. The old implementation assumed wstrings. Rework the class to deal entirely with narrow strings (since wide-strings are not relevant for this utility). Note: This file is only used in some tools. BUG=none TEST=none Review URL: http://codereview.chromium.org/261001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28224 0039d316-1c4b-4281-b951-d872f2087c98
* Add comments setting emacs and vim tab width and expansion variables.sgk@google.com2009-10-061-0/+6
| | | | | | | | BUG=none TEST=successful builds Review URL: http://codereview.chromium.org/256059 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28089 0039d316-1c4b-4281-b951-d872f2087c98
* The Python test server now ignores querystrings params when serving local files.finnur@chromium.org2009-10-021-2/+8
| | | | | | | | | | | | | | | | I'm having no luck getting the try bots to recognize this change to the python file, so I am separating my already LG'ed changelist (http://codereview.chromium.org/246066) into two (this part and a followup patch) in the hopes that my tests (next CL) will succeed. I fixed our python test server to serve files even though there is a querystring in the url (the server basically just ignores the querystring). This is needed in my next cl because the html we serve has js that acts on data in the querystring. Also made it have the right content-header when serving xml files (text/html). TBR=aa BUG=None TEST=None Review URL: http://codereview.chromium.org/242120 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27862 0039d316-1c4b-4281-b951-d872f2087c98
* Replace some net::ERR_FAILED generic error codes with more specific codes.eroman@chromium.org2009-09-241-1/+2
| | | | | | | | | | The goal is to end up with more meaningful errors if a page fails to load. BUG=22623 Review URL: http://codereview.chromium.org/222009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27038 0039d316-1c4b-4281-b951-d872f2087c98
* Add missing gclient dependencies to .gitignore.maruel@chromium.org2009-09-174-345/+345
| | | | | | | | | | | | | | Fix the format of many directories so they don't show up in git status anymore. Run dos2unix on *.cc, caught many inconsistent and CRLF files. TBR=evan TEST=still build, git status shows nothing BUG=none Review URL: http://codereview.chromium.org/211010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26441 0039d316-1c4b-4281-b951-d872f2087c98
* Force inclusion of build/common.gypi for all chromium gyp files.yaar@chromium.org2009-09-151-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | Why: Simpler build code. If everybody includes it, it should be included automatically. Why now: The webkit chromium builds need it be specified, since can't default to build/common.gypi. What was done: 1. build/common.gypi's contents were moved to a new file build/gyp_chromium.gypi 2. tools/gyp/gyp_chromium was moved to build/gyp_chromium and made to automatically include build/gyp_chromium.gypi. 3. lots of gyp files were fixed to not refer to build/common.gypi any more. 4. o3d which also builds independently of chrome, was fixed to have a gyp_o3d that includes gyp_chromium.gypi too. 5. build/common.gypi was left empty, because there are some external projects that still refer to it. Things that are left to do after this patch is in: 1. The following external files (in other repositories) need to stop include common.gypi ./third_party/hunspell/hunspell.gyp ./third_party/icu/icu.gyp ./v8/tools/gyp/v8.gyp 2. Once nobody refers to common.gypi anymore, delete common.gypi -or- Delete gyp_chromium.gypi and move its content back to common.gypi Tested on mac, win and linux. On win, got a few unit tests errors on chrome bookmarks, which should not be related. I'm running again with clobber to verify. Review URL: http://codereview.chromium.org/206006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26302 0039d316-1c4b-4281-b951-d872f2087c98
* Http Cache: Add support for resuming downloading arvargas@google.com2009-09-041-1/+6
| | | | | | | | | | | | resource after the original request was interrupted. BUG=8995 TEST=unittests Review URL: http://codereview.chromium.org/197016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25551 0039d316-1c4b-4281-b951-d872f2087c98
* Create an option to dump the cache to disk files. Because URLs are ↵mbelshe@google.com2009-09-025-45/+473
| | | | | | | | | | | | | frequently large, this requires implementing large filename support (for windows), and of course the filenames need to be encoded with filesystem-safe characters. BUG=none TEST=none Review URL: http://codereview.chromium.org/174391 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25248 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Fix a ton of compiler warnings."tony@chromium.org2009-08-281-4/+1
| | | | | | | | | | | This reverts commit r24792. TBR=estade Review URL: http://codereview.chromium.org/179028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24796 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a ton of compiler warnings.estade@chromium.org2009-08-281-1/+4
| | | | | | | | | | | | | | | Most of these are classes with virtual methods lacking virtual destructors or NULL used in non-pointer context. BUG=none TEST=app_unittests && base_unittests --gtest_filter=-ConditionVariableTest.LargeFastTaskTest patch by Jacob Mandelson <jlmjlm [at] gmail> http://codereview.chromium.org/171028/show git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24792 0039d316-1c4b-4281-b951-d872f2087c98
* Add the ability to not send cookies or send user name/password.levin@chromium.org2009-08-261-0/+21
| | | | | | | | | | | Added unit tests for the above functionality plus the do not save cookies functionality. BUG=http://crbug.com/10961 TEST=Added unit tests for this. Also, this isn't yet called from the rest of the code. Review URL: http://codereview.chromium.org/173206 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24412 0039d316-1c4b-4281-b951-d872f2087c98
* Cleanups for SSLConfigService and SSLConfigServiceManager.mattm@chromium.org2009-08-211-12/+4
| | | | | | | | | | | | | | | | | Make SSLConfig.rev_checking_enable default to true (which also affects the defaults set by SSLConfigServicePref.) Add static SSLConfigService::CreateSystemSSLConfigService which creates a standalone SSLConfigService (either SSLConfigServiceWin or SSLConfigServiceDefaults.) Use CreateSystemSSLConfigService in fetch_client and test_shell_request_context. Merge SSLConfigServiceManagerWin and SSLConfigServiceManagerDefaults into SSLConfigServiceManagerSystem, which uses CreateSystemSSLConfigService. BUG=11507,19290 TEST=only visible change should be linux defaults to having rev checking option enabled. Review URL: http://codereview.chromium.org/173097 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23998 0039d316-1c4b-4281-b951-d872f2087c98
* Pref-backed SSLConfigService for Linux.mattm@chromium.org2009-08-191-2/+17
| | | | | | | | | | Makes SSLConfigService into a ref-counted interface, and makes Profile own an SSLConfigServiceFactory which is used to create the SSLConfigService and pass it through the URLRequestContext on down to where it is actually used. R=eroman,wtc BUG=11507,19290 Review URL: http://codereview.chromium.org/165003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23757 0039d316-1c4b-4281-b951-d872f2087c98
* Reference count ProxyService.eroman@chromium.org2009-08-181-3/+3
| | | | | | | | | | | | | This is necessary since ProxyService is getting shared between chrome's url request contexts (off the record, media), and the current way it is being shared could result in free memory read/writes during shutdown. This is a step towards fixing http://crbug.com/15289. BUG=http://crbug.com/15289 TEST=The existing tests should continue to pass following this refactor. Review URL: http://codereview.chromium.org/165430 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23612 0039d316-1c4b-4281-b951-d872f2087c98
* Speed up net_unittests a bit by re-using launched test server.phajdan.jr@chromium.org2009-08-141-2/+23
| | | | | | | | | | | | | | On POSIX it makes the server fork a separate process for each request for better test isolation. Starting with just few tests to limit impact of an eventual breakage. The results are promising. TEST=none BUG=none Review URL: http://codereview.chromium.org/164522 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23481 0039d316-1c4b-4281-b951-d872f2087c98
* LoadLog is used as an output parameter, reorder it to the last parameter.willchan@chromium.org2009-08-141-1/+1
| | | | | | Review URL: http://codereview.chromium.org/164531 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23419 0039d316-1c4b-4281-b951-d872f2087c98
* Add a "LoadLog" parameter to transactions, hostresolver, clientsocketpool ↵ericroman@google.com2009-08-121-1/+2
| | | | | | | | and proyxservice.This dependency comes from the parent URLRequest, and is used as a container for per-request profiling data.This change is strictly a no-op refactor -- the parameter is unused, and LoadLog does nothing.BUG=http://crbug.com/14478TEST=none -- just needs to compile and pass existing tests.DESIGN=<http://docs.google.com/Doc?id=dfhcnb2v_21gbtrcpr3&hl=en> Review URL: http://codereview.chromium.org/126303 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23127 0039d316-1c4b-4281-b951-d872f2087c98
* Make fetch_client work on POSIX.phajdan.jr@chromium.org2009-08-071-2/+2
| | | | | | | | | TEST=none BUG=none Review URL: http://codereview.chromium.org/164107 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22775 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Remove remaining uses of RankingsNode.pointer.rvargas@google.com2009-07-301-1/+1
| | | | | | | | | | | | | We now have a map of open entries so we don't need to do a lookup through the rankings node anymore. This simplifies the 64 bit version of the code. BUG=17881 TEST=unittests Review URL: http://codereview.chromium.org/159643 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22074 0039d316-1c4b-4281-b951-d872f2087c98
* Add support to URLRequest for deferring redirects.darin@chromium.org2009-07-231-0/+4
| | | | | | | | | | | | | | | | | | | | I chose to add an out parameter to OnReceivedRedirect because it allows for the default behavior to remain the same. I considered adding a ContinueAfterRedirect method that all OnReceivedRedirect implementations would need to call, but this caused one annoying problem: In the case of a ChromePlugin, it is possible for the URLRequest to get deleted inside the handler for the redirect. This would make it hard to subsequently call a method on the URLRequest since I would need to have a way to determine if the URLRequest had been deleted. TEST=covered by unit tests BUG=16413,6442 R=eroman,wtc Review URL: http://codereview.chromium.org/155897 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21417 0039d316-1c4b-4281-b951-d872f2087c98
* Refactorings surrounding HostResolver:ericroman@google.com2009-07-151-1/+3
| | | | | | | | | | | | | | | | | | | | | | (1) Extract HostResolver to an interface. The existing concrete implementation is now named HostResolverImpl. This makes it possible to create mocks with more complex behavior (i.e. choose via rules if response will be sync vs async). (2) Transform HostMapper into HostResolverProc. Conceptually HostResolverProc maps a hostname to a socket address, whereas HostMapper mapped a hostname to another hostname (so you were still at the mercy of the system's host resolver). With HostResolverProc you can specify the exact AddressList, making it possible to run tests requiring IPv6 socketaddrs on systems (like WinXP) that don't actually support it. (3) Add a MockHostResolver implementation of HostResolver. This replaces the [ScopedHostMapper + RuleBasedHostMapper + HostResolver] combo. It is less clunky and a bit more expressive. BUG=http://crbug.com/16452 R=willchan TEST=existing Review URL: http://codereview.chromium.org/149511 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20795 0039d316-1c4b-4281-b951-d872f2087c98
* Fix 15 coverity complaints.rvargas@google.com2009-07-013-18/+18
| | | | | | | | | | | | Most of the changes are cosmetic, but there is also a memory leak in CreateExpiredServer. BUG=none TEST=none Review URL: http://codereview.chromium.org/153001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19788 0039d316-1c4b-4281-b951-d872f2087c98
* Make net::HostResolver refcounted.ericroman@google.com2009-06-271-3/+3
| | | | | | | | | | | This way it can be properly shared between the url request contexts, and the dns prefetcher, and dns observer. BUG=http://crbug.com/14664 TEST=existing unit tests. Review URL: http://codereview.chromium.org/149053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19451 0039d316-1c4b-4281-b951-d872f2087c98
* Reverting 19425.ericroman@google.com2009-06-261-3/+3
| | | | | | Review URL: http://codereview.chromium.org/147242 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19432 0039d316-1c4b-4281-b951-d872f2087c98
* Make net::HostResolver refcounted.ericroman@google.com2009-06-261-3/+3
| | | | | | | | | | | This way it can be properly shared between the url request contexts, and the dns prefetcher, and dns observer. BUG=http://crbug.com/14664 TEST=existing unit tests. Review URL: http://codereview.chromium.org/149053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19425 0039d316-1c4b-4281-b951-d872f2087c98
* Move socket related files from net/base to net/socket.willchan@chromium.org2009-06-221-1/+1
| | | | | | Review URL: http://codereview.chromium.org/144009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18985 0039d316-1c4b-4281-b951-d872f2087c98
* Compile fetch_server on POSIX.phajdan.jr@chromium.org2009-06-172-5/+8
| | | | | | | | | | | | More tidy cross-platformness (typedefs instead of #defines) and other simple related cleanups. TEST=none http://crbug.com/14191 Review URL: http://codereview.chromium.org/126218 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18607 0039d316-1c4b-4281-b951-d872f2087c98
* Make HttpNetworkLayer tests network-independent.phajdan.jr@chromium.org2009-06-161-3/+7
| | | | | | | | | | | | This includes a small refactoring which allows using a different socket factory. TEST=Covered by net_unittests. BUG=http://crbug.com/14107 Review URL: http://codereview.chromium.org/126147 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18499 0039d316-1c4b-4281-b951-d872f2087c98
* * Avoid doing concurrent DNS resolves of the same hostname in HostResolver.ericroman@google.com2009-06-121-2/+4
| | | | | | | | | | | | | | | | * Add a 1 minute cache for host resolves. * Refactor HostResolver to handle multiple requests. * Make HostResolver a dependency of URLRequestContext. operate the HostResolver in async mode for proxy resolver (bridging to IO thread). TEST=unittests BUG=13163 Review URL: http://codereview.chromium.org/118100 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18236 0039d316-1c4b-4281-b951-d872f2087c98
* Add svn:eol-style LF to some file.ericroman@google.com2009-06-051-185/+184
| | | | | | | | | | BUG=NONE TEST=NONE TBR=wtc Review URL: http://codereview.chromium.org/114084 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17784 0039d316-1c4b-4281-b951-d872f2087c98
* Change timeout settings in CacheTest tohuanr@chromium.org2009-05-231-2/+2
| | | | | | | | make it run faster. Review URL: http://codereview.chromium.org/115678 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16833 0039d316-1c4b-4281-b951-d872f2087c98
* Fix testserver to return a correct MIME-type header.ericroman@google.com2009-05-071-1/+2
| | | | | | | | | | | | Originally, testserver was sending "Content-type: text/html" header regardless of a file extension, due to a bug in TestPageHandler.GetMIMETypeFromName. Patch by Yuta Kitamura <yutak@google.com>. Original code review: <http://codereview.chromium.org/100357> Review URL: http://codereview.chromium.org/115058 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15510 0039d316-1c4b-4281-b951-d872f2087c98
* A utility driver for doing client/server HTTP transactionmbelshe@google.com2009-05-0610-0/+698
| | | | | | | | | | | | tests. This is an initial codebase - there is a lot of work to do. But I wanted to get an initial version checked in. http://crbug.com/6754 Review URL: http://codereview.chromium.org/99333 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15360 0039d316-1c4b-4281-b951-d872f2087c98
* Deprecate wstring version of PathService::Get() in net.thestig@chromium.org2009-05-011-8/+8
| | | | | | Review URL: http://codereview.chromium.org/100240 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15088 0039d316-1c4b-4281-b951-d872f2087c98
* Scrape search definitions from forms that have onsubmit handlers. The ↵ben@chromium.org2009-04-101-1/+6
| | | | | | | | | | | | | | | | scraping is done after submit events are handled by the page DOM so doing this is safe. Adds test infrastructure for determining that scraping occurs on submit: - allow testserver to be configured to serve pages from / on the server - provide a ui test util that navigates and waits for N subsequent redirections/navigations before returning control to the test to handle automated submission Eric, please review the test server changes. Scott, please look over everything else. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=13444 Review URL: http://codereview.chromium.org/62145 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13491 0039d316-1c4b-4281-b951-d872f2087c98
* revert until I can figure out why the tests are hangingben@chromium.org2009-04-091-6/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13448 0039d316-1c4b-4281-b951-d872f2087c98
* Scrape search definitions from forms that have onsubmit handlers. The ↵ben@chromium.org2009-04-091-1/+6
| | | | | | | | | | | | | | scraping is done after submit events are handled by the page DOM so doing this is safe. Adds test infrastructure for determining that scraping occurs on submit: - allow testserver to be configured to serve pages from / on the server - provide a ui test util that navigates and waits for N subsequent redirections/navigations before returning control to the test to handle automated submission Eric, please review the test server changes. Scott, please look over everything else. Review URL: http://codereview.chromium.org/62145 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13444 0039d316-1c4b-4281-b951-d872f2087c98
* Add GYP file tld_cleanup tool.agl@chromium.org2009-04-021-0/+25
| | | | | | | http://codereview.chromium.org/58010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13047 0039d316-1c4b-4281-b951-d872f2087c98
* Remove the checked-in scons configuration files.sgk@google.com2009-04-011-79/+0
| | | | | | Review URL: http://codereview.chromium.org/53121 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12982 0039d316-1c4b-4281-b951-d872f2087c98
* Respect cookies set in a 401 responses when restarting the http transaction.ericroman@google.com2009-03-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | There are two parts to this change: (1) rebuild the request cookies before each transaction restart for authentication (2) notify the URLRequestHttpJob of header completion before *each* transaction restart for authentication By "each transaction" I mean the automatic restarts that don't require user input, such as: - replying to the first step of NTLM - selecting identity embedded in URL - selecting identity in auth-cache Needing to notify URLRequestHttpJob for these intermediate restarts is a consequence of cookie store management being done outside of HttpNetworkTransaction. After updating the cookie store, URLRequestHttpJob now tests |HttpTransaction::IsReadyToRestartForAuth()| to check whether the notification was informational or an identity is actually needed. R=wtc BUG=6450 Review URL: http://codereview.chromium.org/51004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12635 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: First pass to make it possible to havervargas@google.com2009-03-251-3/+6
| | | | | | | | | | | | multiple instances of BackendImpl. We need multiple objects to be able to support media files on the cache. After this change, histograms will be the only thing that get messed up by multiple disk caches. Review URL: http://codereview.chromium.org/49027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12520 0039d316-1c4b-4281-b951-d872f2087c98
* NO CODE CHANGEdeanm@chromium.org2009-03-112-2/+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
* Slight code change to make some global variables const.maruel@google.com2009-03-101-22/+46
| | | | | | | Fix >80 cols lines. Review URL: http://codereview.chromium.org/42013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11342 0039d316-1c4b-4281-b951-d872f2087c98
* fixes for python 2.6 warnings in the testserver.thomasvl@chromium.org2009-03-061-7/+13
| | | | | | | BUG=8300 Review URL: http://codereview.chromium.org/40235 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11142 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes CRLF and trailing white spaces.maruel@chromium.org2009-03-052-8/+8
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
* Have tld_cleanup generate a .cc file that contains the effectivetc@google.com2009-02-242-10/+35
| | | | | | | | | | | | tld data. This makes the build dependencies easier (helpful for grit and gyp) and brings in the effective tld data on mac. BUG=6076 Review URL: http://codereview.chromium.org/31004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10245 0039d316-1c4b-4281-b951-d872f2087c98
* Add a unit test for ERR_UNEXPECTED_SERVER_AUTH.wtc@chromium.org2009-02-141-0/+16
| | | | | | | | | | | | Remove the obsolete change to URLRequestHttpJob::IsRedirectResponse, which was accidentally checked in. R=eroman BUG=7338 Review URL: http://codereview.chromium.org/20279 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9816 0039d316-1c4b-4281-b951-d872f2087c98
* Extend the IOBuffer to the disk cache.rvargas@google.com2009-02-121-4/+8
| | | | | | | | | | | This is cleanup from bug 5325. Original code review: http://codereview.chromium.org/20134/show Review URL: http://codereview.chromium.org/20251 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9626 0039d316-1c4b-4281-b951-d872f2087c98