summaryrefslogtreecommitdiffstats
path: root/net
Commit message (Collapse)AuthorAgeFilesLines
* Fix TCPClientSocketPool synchronous dns resolution + connect code path.willchan@chromium.org2009-06-092-79/+60
| | | | | | | | BUG=http://www.crbug.com/13289 Review URL: http://codereview.chromium.org/119251 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17913 0039d316-1c4b-4281-b951-d872f2087c98
* Don't save the cert chain in cert_list_.ukai@chromium.org2009-06-082-32/+26
| | | | | | | | | BUG=none TEST=net_unittests passes Review URL: http://codereview.chromium.org/119165 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17848 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crash on fallback in HttpNetworkTransaction::ReconsiderProxyAfterError().willchan@chromium.org2009-06-062-1/+48
| | | | | | | | | | If the socket doesn't exist, don't try to Disconnect() it. BUG=http://www.crbug.com/13375 TEST=See bug for repro. Review URL: http://codereview.chromium.org/119228 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17808 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
* Disk cache: Report more info from the current experiment.rvargas@google.com2009-06-053-19/+43
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/119218 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17772 0039d316-1c4b-4281-b951-d872f2087c98
* Send the "Proxy-Connection: keep-alive" header with HTTP CONNECTwtc@chromium.org2009-06-052-12/+21
| | | | | | | | | | | | | | requests for compatibility with HTTP/1.0 proxies such as Squid. This is required for NTLM authentication. Fix some cpplint.py nits in http_network_transaction_unittest.cc. R=eroman BUG=http://crbug.com/8771 TEST=net_unittests passes all tests Review URL: http://codereview.chromium.org/118316 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17761 0039d316-1c4b-4281-b951-d872f2087c98
* Revert r17673, except for the code cleanup.wtc@chromium.org2009-06-051-6/+38
| | | | | | | | | | | | I will try the real fix (sending the "Proxy-Connection: keep-alive" header with HTTP CONNECT requests) next. R=eroman BUG=http://crbug.com/8771 TEST=none Review URL: http://codereview.chromium.org/114083 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17759 0039d316-1c4b-4281-b951-d872f2087c98
* Don't consider a certificate revoked if we don't havewtc@chromium.org2009-06-051-2/+5
| | | | | | | | | | | | | | | fresh revocation status of the certificate. We haven't written the code for NSS to use our network stack to download CRLs or talk to OCSP responders, so NSS doesn't have any revocation info. R=agl,ukai BUG=http://crbug.com/13336 TEST=none (requires a Linux system with NSS 3.12.3) Review URL: http://codereview.chromium.org/118314 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17756 0039d316-1c4b-4281-b951-d872f2087c98
* Use res_ninit for thread safety and a timer for reloading resolv.conf on Linux.evan@chromium.org2009-06-051-2/+76
| | | | | | | | | | | | | | We will only reload resolv.conf once per second per thread when DNS lookups fail. This should match the behaviour of mozilla. [retry of r17530, passes Valgrind now] BUG=12740 Review URL: http://codereview.chromium.org/118061 Patch from Craig Schlenter <craig.schlenter@gmail.com>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17750 0039d316-1c4b-4281-b951-d872f2087c98
* Add two small features to the HttpCache for benchmarking/debugging.mbelshe@google.com2009-06-053-11/+55
| | | | | | | | | | | | | | | | | | The first exposes a method to close all idle sockets. This allows me to create benchmark tests in the app which can close connections before starting the test for better simulations. The second change is to expose cache modes for cache disabled and cache bypassed. DISABLE sets the LOAD_DISABLE_CACHE on every request; BYPASS sets the LOAD_BYPASS_CACHE on every request. TEST=http_cache_unittest.cc BUG=6754 Review URL: http://codereview.chromium.org/119189 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17720 0039d316-1c4b-4281-b951-d872f2087c98
* Make ClientSocketPool an interface. Move ClientSocketPool code into ↵willchan@chromium.org2009-06-057-206/+267
| | | | | | | | | | TCPClientSocketPool. Strictly a refactoring. BUG=http://www.crbug.com/13289 TEST=still builds and tests pass Review URL: http://codereview.chromium.org/119184 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17710 0039d316-1c4b-4281-b951-d872f2087c98
* Update google's certificate to the latest version.ukai@chromium.org2009-06-051-34/+34
| | | | | | | | | | | | | | | Current cert was already expired on Sat May 2 17:02:55 UTC 2009. Update to the cert of validity Not Before: Mar 18 23:35:19 2008 GMT Not After : Mar 18 23:35:19 2011 GMT BUG=none TEST=net_unittests passes Review URL: http://codereview.chromium.org/118231 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17706 0039d316-1c4b-4281-b951-d872f2087c98
* Check in the fourth Portable FTP CL from Ibrar Ahmedwtc@chromium.org2009-06-056-108/+285
| | | | | | | | | | | | | | | | <ibrar.ahmad@gmail.com>. Now we can browse some ftp sites and can download files. There are some TODO yet to be fixed. Original review: http://codereview.chromium.org/115291 R=wtc BUG=http://crbug.com/4965 TEST=none Review URL: http://codereview.chromium.org/118274 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17703 0039d316-1c4b-4281-b951-d872f2087c98
* Reduce probability of SDCH holdback to 1%jar@chromium.org2009-06-051-2/+2
| | | | | | | | | | | | Anticipating a broader test base, I wanted to reduce the percentage of uses that were "holdback" (sdch not used when it was available). This should reduce the impact on users, and also be sufficient to get verification statistics from a larger group. r=huanr Review URL: http://codereview.chromium.org/118287 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17700 0039d316-1c4b-4281-b951-d872f2087c98
* Prevent SDCH from re-trying to download a dicitionaryjar@chromium.org2009-06-051-0/+1
| | | | | | | | | | | | | Some dicitoaries provided by an SDCH server may be larger than allowed by Chromium (which holds the dictionary memory-resident). This CL prevents Chromium from endlessly re-trying such dicitonary loads, BUG=7722 r=huanr Review URL: http://codereview.chromium.org/119198 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17699 0039d316-1c4b-4281-b951-d872f2087c98
* Use a "SessionDependencies" helper in the http unit tests.ericroman@google.com2009-06-051-194/+188
| | | | | | | | This avoids some duplication in setup. Review URL: http://codereview.chromium.org/118293 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17694 0039d316-1c4b-4281-b951-d872f2087c98
* For connection-based authentication schemes such as NTLM,wtc@chromium.org2009-06-041-41/+13
| | | | | | | | | | | | we keep the connection alive even if the server or proxy tells us to close it. R=eroman BUG=http://crbug.com/8771 TEST=none Review URL: http://codereview.chromium.org/119068 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17673 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Interface for the sparse cache support.rvargas@google.com2009-06-047-2/+171
| | | | | | | | | | | | This is just the interface declaration plus a mocked implementation of the interface. BUG=12258 TEST=none Review URL: http://codereview.chromium.org/119072 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17669 0039d316-1c4b-4281-b951-d872f2087c98
* To show IDN in view-source URLs, add special handling for view-source scheme inbrettw@chromium.org2009-06-042-1/+81
| | | | | | | | | | | | net::FormatUrl(). TEST=add a unit test BUG=3991 Original review: http://codereview.chromium.org/118071 Checked in for tkent@google.com git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17661 0039d316-1c4b-4281-b951-d872f2087c98
* Call CertVerifier to verify certificate.ukai@chromium.org2009-06-042-75/+102
| | | | | | | | | BUG=10911 TEST=net_unittests passes Review URL: http://codereview.chromium.org/115913 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17624 0039d316-1c4b-4281-b951-d872f2087c98
* Update thawte's certificate to the latest version.ukai@chromium.org2009-06-041-69/+84
| | | | | | | | | | | | | | | | Current cert was already expired on Jan 17 23:59:59 UTC 2009, so we may fail to verify the certificate while checking EV-ness of it. Update to the cert of validity Not Before: Nov 19 00:00:00 2008 GMT Not After : Jan 17 23:59:59 2010 GMT BUG=none TEST=net_unittests passes with ALLOW_EXTERNAL_ACCESS=1 Review URL: http://codereview.chromium.org/118154 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17623 0039d316-1c4b-4281-b951-d872f2087c98
* Disable the leaky test.willchan@chromium.org2009-06-041-1/+1
| | | | | | Review URL: http://codereview.chromium.org/118222 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17613 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Fix valgrind/purify errors with ↵willchan@chromium.org2009-06-041-6/+7
| | | | | | | | | | | ClientSocketPoolTest_ConnectCancelConnect." This reverts commit git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17610 0039d316-1c4b-4281-b951-d872f2087c98 I was dumb, this freezes it. Review URL: http://codereview.chromium.org/119153 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17612 0039d316-1c4b-4281-b951-d872f2087c98
* Fix valgrind/purify errors with ClientSocketPoolTest_ConnectCancelConnect.willchan@chromium.org2009-06-041-7/+6
| | | | | | | | The ConnectingSocket never ran to completion. Call WaitForResult() to force it to finish and delete itself. Review URL: http://codereview.chromium.org/119152 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17610 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Use res_ninit for thread safety and a timer for reloading ↵willchan@chromium.org2009-06-041-72/+1
| | | | | | | | | | | | resolv.conf on Linux." This reverts commit d4f0dede964549af67f275ac6296c5e9add3fb03. It caused a valgrind error. TBR=craig.schlenter@gmail.com Review URL: http://codereview.chromium.org/118220 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17607 0039d316-1c4b-4281-b951-d872f2087c98
* Reland my ClientSocketPool refactor again...willchan@chromium.org2009-06-0411-377/+894
| | | | | | | | | | The bug was that the handle was getting reused, so the ConnectingSocket doesn't know that it got canceled. It just keeps chugging away. I added a map to keep track of the ConnectingSockets so they can be canceled if we detect a reuse. TBR=wtc Review URL: http://codereview.chromium.org/118219 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17606 0039d316-1c4b-4281-b951-d872f2087c98
* Sigh, revert "Reland my ClientSocketPool refactor."willchan@chromium.org2009-06-0411-794/+377
| | | | | | | | | This reverts commit d3d93c94d040db33599b798723ac1fef560b653a. It broke document-location-click-timeout.html again =/ Review URL: http://codereview.chromium.org/119143 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17591 0039d316-1c4b-4281-b951-d872f2087c98
* Reland my ClientSocketPool refactor.willchan@chromium.org2009-06-0411-377/+794
| | | | | | | | | | | Fixed a bug where we were double compensating for active_socket_count in CancelRequest and OnIOComplete. Added ClientSocketPoolTest_TwoRequestsCancelOne to catch this. Triggered a DCHECK in debug mode before I removed the extra code in OnIOComplete. BUG=http://www.crbug.com/13289 Review URL: http://codereview.chromium.org/118172 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17588 0039d316-1c4b-4281-b951-d872f2087c98
* Disable the http cache when fetching PAC scripts. Also adds an extra log ↵eroman@chromium.org2009-06-034-10/+46
| | | | | | | | | | | | | | statement for when response is non-200. The cache is disabled to avoid problems when switching networks (wouldn't want to re-use cached response from old network after switching to new network). This is only a partial piece for 12293 (still needs to re-trigger auto-detect on network change). BUG=12293 Review URL: http://codereview.chromium.org/118032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17572 0039d316-1c4b-4281-b951-d872f2087c98
* Enable a test, by masking failures if the system does not support IPv6.eroman@chromium.org2009-06-031-7/+11
| | | | | | Review URL: http://codereview.chromium.org/114061 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17571 0039d316-1c4b-4281-b951-d872f2087c98
* Avoiding IO completion callback during the closinghuanr@chromium.org2009-06-034-12/+38
| | | | | | | | | | of FileStream. BUG=8942 Review URL: http://codereview.chromium.org/112090 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17560 0039d316-1c4b-4281-b951-d872f2087c98
* Update some comments in url_request.h to clarify that once the request is ↵ericroman@google.com2009-06-031-3/+5
| | | | | | | | | | | | | | | deleted/cancelled, the delegate should never be called again. (The text added to URLRequest::Cancel() was copied from URLRequest::~URLRequest()). The comment change in resource_dispatcher_host.cc is an unrelated name fix. TEST=0 BUG=0 Review URL: http://codereview.chromium.org/118151 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17555 0039d316-1c4b-4281-b951-d872f2087c98
* Use res_ninit for thread safety and a timer for reloading resolv.conf on Linux.evan@chromium.org2009-06-031-1/+72
| | | | | | | | | | | | We will only reload resolv.conf once per second per thread when DNS lookups fail. This should match the behaviour of mozilla. BUG=12740 Review URL: http://codereview.chromium.org/118061 Patch from Craig Schlenter <craig.schlenter@gmail.com>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17530 0039d316-1c4b-4281-b951-d872f2087c98
* Increase cookie limit to 3000. This matches Firefox 3.5 and Firefox ↵pkasting@chromium.org2009-06-032-6/+6
| | | | | | | | trunk.BUG=8850 Review URL: http://codereview.chromium.org/118011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17501 0039d316-1c4b-4281-b951-d872f2087c98
* Reduce header dependencies in base/phajdan.jr@chromium.org2009-06-032-0/+2
| | | | | | | | Also adds more explicit #includes for needed things. Review URL: http://codereview.chromium.org/118162 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17479 0039d316-1c4b-4281-b951-d872f2087c98
* Local text file with spaces in filename is urlencoded in tab titlemhm@chromium.org2009-06-036-56/+86
| | | | | | | | | | | | | | When viewing a local text file with spaces in filename, it is still urlencoded. Filename should be displayed with spaces, not with urlencoding. It would be more user-friendly. Since net::FormatURL is already implemented, using it would be great. But it doesn't escape SPACES, just NORMAL, it doesn't even escape unicode. I plumbed out a unescapeurl that could be used whether we allow conversion of spaces or not. BUG=8775 (http://crbug.com/8775) TEST=Tested whether the input is escaped in the navigational context and ran the net tests New Review: http://codereview.chromium.org/118059 Review URL: http://codereview.chromium.org/56053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17462 0039d316-1c4b-4281-b951-d872f2087c98
* Parsing routines for X-Force-TLS header.abarth@chromium.org2009-06-024-1/+230
| | | | | | | | | | R=darin BUG=http://crbug.com/12190 TEST=ForceTLSStateTest.BogusHeaders, ForceTLSStateTest.ValidHeaders Review URL: http://codereview.chromium.org/118049 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17377 0039d316-1c4b-4281-b951-d872f2087c98
* Move X509Certificate::HasExpired to x509_certificate.cc.ukai@chromium.org2009-06-014-14/+5
| | | | | | | | | | | All versions have implemented valid_expiry(), so we can use common code for X509Certificate::HasExpired. R=wtc Review URL: http://codereview.chromium.org/118069 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17311 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: fix the description of data\cache_tests\bad_rankings2rvargas@google.com2009-05-291-2/+2
| | | | | | | | | | | BUG=none TEST=none No actual code change. Review URL: http://codereview.chromium.org/118017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17236 0039d316-1c4b-4281-b951-d872f2087c98
* Remove code path that passes a file handle to the rendererhclam@chromium.org2009-05-2917-359/+6
| | | | | | | | | | | | | | | | | | | | | | Since the code now does range request without any caching the code path for passing file handle is not used any more. Changes: 1. Remove response_data_file in webkit_glue::ResourceResponseHead 2. Remove response_data_file in net::ResourceInfo 3. Remove code that passes file handle using IPC 4. Remove code that passes file hadnle from network layer to ResourceDispatcherHost 5. Remove MediaResourceHandler 6. Remove code in disk_cache that expose the file handle 7. Remove ChromeURLRequestContext::CreateOffTheRecordForMedia() so no more OTR request context for media, in OTR mode simply memory cache is used 8. Reset cache size for media cache to default BUG=12249 BUG=12256 Review URL: http://codereview.chromium.org/113931 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17227 0039d316-1c4b-4281-b951-d872f2087c98
* Handle mimetype queries for media fileshclam@chromium.org2009-05-292-3/+42
| | | | | | | | | | Added code path from WebKit to net::mimt_util to query supported mime-types for media files. BUG=12777 Review URL: http://codereview.chromium.org/114060 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17225 0039d316-1c4b-4281-b951-d872f2087c98
* Reduce header dependencies in net/phajdan.jr@chromium.org2009-05-2941-19/+50
| | | | | | | | TEST=none Review URL: http://codereview.chromium.org/115870 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17178 0039d316-1c4b-4281-b951-d872f2087c98
* Remember the intermediate CA certs if the server sends them to us.ukai@chromium.org2009-05-292-10/+147
| | | | | | | | | BUG=10911 TEST=net_unittests passes Review URL: http://codereview.chromium.org/115700 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17168 0039d316-1c4b-4281-b951-d872f2087c98
* Detach verify thread from NSPR on linux.ukai@chromium.org2009-05-291-0/+14
| | | | | | | | | | | | | The threads in our thread pool terminate after we have called PR_Cleanup. Unless we detach them from NSPR, if we use CertVerifier, net_unittests dies with segfault on shutdown. BUG=10911 TEST=net_unittests passes with code that uses CertVerifier. Review URL: http://codereview.chromium.org/115856 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17160 0039d316-1c4b-4281-b951-d872f2087c98
* Implement X509Certificate::Verify for Linux.ukai@chromium.org2009-05-281-7/+270
| | | | | | | | | | | | | | | | | | | | | | | Use CERT_PKIXVerifyCert() with CRL to verify certificate. With OCSP, CERT_PKIXVerifyCert() failed with SEC_ERROR_INVALID_ARGS. Increase stack size. It was not enough size if we use CERT_PKIXVerifyCert() on some sites. For example, https://www.google.com/ works, but https://bugs.webkit.org/ or https://www.thawte.com/ would die by SIGSEGV. This is because pkix_List_Destroy() routine destroys PKIX_List recursively, so if there are some long PKIX_Lists, it consumes stack a lot and dies by stack overflow. Note that X509Certificate::Verify isn't used in SSLClientSocketNSS yet. BUG=10911 TEST=net_unittests passes Review URL: http://codereview.chromium.org/113578 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17071 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Fix a signed / unsigned comparison on cl 17052rvargas@google.com2009-05-281-2/+2
| | | | | | | | TBR=nsylvain Review URL: http://codereview.chromium.org/115848 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17053 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Reset mask_ when the disk cache is being restarted.rvargas@google.com2009-05-288-0/+137
| | | | | | | | | | | | | | | It is possible that the size for the index table is reduced when the cache is restarted (the available disk space could be lower than what it was when the cache was originally created). If that is the case, not resetting mask_ to 0 will prevent the mask to be set correctly for the new table size, resulting in a crash. BUG=12378 TEST=unittests Review URL: http://codereview.chromium.org/113930 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17052 0039d316-1c4b-4281-b951-d872f2087c98
* Work around linux resolver problem where changes to resolv.conf go unnoticed ↵evan@chromium.org2009-05-271-0/+10
| | | | | | | | | | | | | | in some distributions. BUG=11380 TEST=Start chrome with empty resolv.conf, fix resolv.conf; chrome should be able to resolve sites. Review URL: http://codereview.chromium.org/113904 Patch from Craig Schlenter <craig.schlenter@gmail.com>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17005 0039d316-1c4b-4281-b951-d872f2087c98
* Decompress .svgz files from disk.thestig@chromium.org2009-05-272-0/+13
| | | | | | | | BUG=9936 TEST=Download a .svgz file to local disk, then attempt to view it. Please make sure it didn't get decompressed during the download. Review URL: http://codereview.chromium.org/99109 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17000 0039d316-1c4b-4281-b951-d872f2087c98
* HttpResponseHeaders::GetContentRange() to handle implied LWShclam@chromium.org2009-05-262-20/+78
| | | | | | | | | | | There was a bug in HttpResponseHeaders::GetContentRange() that it didn't respect implied LWS rule, i.e. there can be arbitrary number of spaces in the header value between tokens. TEST=HttpResponseHeaders.GetContentRange Review URL: http://codereview.chromium.org/113675 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16921 0039d316-1c4b-4281-b951-d872f2087c98