summaryrefslogtreecommitdiffstats
path: root/net
Commit message (Collapse)AuthorAgeFilesLines
* Original patch by pmarks@google.com (see http://codereview.chromium.org/113944)ericroman@google.com2009-06-235-49/+47
| | | | | | | | | | | | | | | | | | | | | | | - Pull in googleurl r107, which includes the new CanonicalizeHostVerbose() function: http://code.google.com/p/google-url/source/detail?r=107 - Atomically update Chromium to make use of this new function. This allows us to extract better information about IP addresses using fewer, and cleaner, calls to googleurl. - Also, change a call to CanonicalizeIPAddress() to stay compatible with r107. The upshot of all this is, Chrome will no longer try to connect to IPv4 addresses with overflow "http://192.168.0.257", or hostnames surrounded by square brackets "http://[google.com]" BUG=none TEST={unit_tests,googleurl_unittests,net_unittests} Review URL: http://codereview.chromium.org/146053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19076 0039d316-1c4b-4281-b951-d872f2087c98
* Disk Cache: Fix a dumb warning about a variable not being initialized.rvargas@google.com2009-06-231-1/+1
| | | | | | | | | TBR=nsylvain BUG=none Review URL: http://codereview.chromium.org/146054 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19071 0039d316-1c4b-4281-b951-d872f2087c98
* Disk Cache: Implement GetAvailableRange for the regular disk cache.rvargas@google.com2009-06-233-17/+136
| | | | | | | | | | | This is required to enable sparse caching. BUG=12258 TEST=unittest Review URL: http://codereview.chromium.org/146005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19069 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crash in ClientSocketPoolBase.willchan@chromium.org2009-06-233-48/+62
| | | | | | | | | | If a ConnectingSocket fails, we need to try to process a pending request. BUG=http://crbug.com/14814 TEST=See bug for repro steps. Review URL: http://codereview.chromium.org/146037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19067 0039d316-1c4b-4281-b951-d872f2087c98
* Following the style guide, replace the overloaded operator==wtc@chromium.org2009-06-232-2/+2
| | | | | | | | | | | with the Equals method. R=eroman BUG=http://crbug.com/318 TEST=none Review URL: http://codereview.chromium.org/146040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19056 0039d316-1c4b-4281-b951-d872f2087c98
* Revert the previous checkin r19037 because it causes test_shell towtc@chromium.org2009-06-231-2/+2
| | | | | | | | | | | crash when running LayoutTests/security/block-test.html. TBR=jshin BUG=http://crbug.com/4965 TEST=none Review URL: http://codereview.chromium.org/147036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19042 0039d316-1c4b-4281-b951-d872f2087c98
* Use the new portable FTP implementation on non-Windows platforms.wtc@chromium.org2009-06-231-2/+2
| | | | | | | | | | | Note: the new FTP is still work in progress. R=dank BUG=http://crbug.com/4965 TEST=none Review URL: http://codereview.chromium.org/119342 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19037 0039d316-1c4b-4281-b951-d872f2087c98
* Privacy Blacklist SketelonAdded code hooks to serve as place holders for the ↵idanan@chromium.org2009-06-232-3/+25
| | | | | | | | | | | implementationof the privacy blacklist. The --privacy-blacklist option was addedwhich will eventually is used to activate the code.This is work-in-progress code which effectively makes a couple morepointer-checks when the --privacy-blacklist is not specified. Whenit is specified, some of the blacklist code is executed but theblacklist is always empty and therefore has no impact on browsing. BUG=none TEST=Blacklist* Review URL: http://codereview.chromium.org/119313 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19033 0039d316-1c4b-4281-b951-d872f2087c98
* Define the == operator for X509Certificate::Fingerprint.wtc@chromium.org2009-06-232-3/+7
| | | | | | | | | R=eroman BUG=http://crbug.com/318 TEST=none Review URL: http://codereview.chromium.org/140034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19029 0039d316-1c4b-4281-b951-d872f2087c98
* Use LOAD_VERIFY_EV_CERT to verify EV-ness in Verify().ukai@chromium.org2009-06-2311-50/+94
| | | | | | | | | | | | | | | | | If LOAD_VERIFY_EV_CERT is requested on load_flags and revokation checking is performed, Verify() peforms EV certificate verification as well, and sets CERT_STATUS_IS_EV in verify_result. Eliminate X509Certificate::IsEV() BUG=3592 TEST=net_unittests with ALLOW_EXTERNAL_ACCESS=1, \ visit https://www.thawte.com/ and shows EV info. Review URL: http://codereview.chromium.org/125120 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19011 0039d316-1c4b-4281-b951-d872f2087c98
* Add some other missing header files to net.gyp.ericroman@google.com2009-06-231-0/+14
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/144001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19006 0039d316-1c4b-4281-b951-d872f2087c98
* Adding socks4 support for chromium. tested for windows and linux.arindam@chromium.org2009-06-2310-10/+739
| | | | | | | | | | | | | | | includes socks4, socks4a TEST=change proxy settings to use proxy and set only the socks proxy fields (others must remain blank). Use CCProxy for windows or 'ssh -D' for linux / cygwin if trying it via localhost. Browser should successfully open both http and https URLs. tests are also at HttpNetworkTransactionTest.SOCKS* BUG=none Review URL: http://codereview.chromium.org/113811 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19005 0039d316-1c4b-4281-b951-d872f2087c98
* Move socket related files from net/base to net/socket.willchan@chromium.org2009-06-2245-147/+150
| | | | | | Review URL: http://codereview.chromium.org/144009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18985 0039d316-1c4b-4281-b951-d872f2087c98
* Http cache: Return valid Content-Range headers for a byte range request.rvargas@google.com2009-06-227-20/+312
| | | | | | | | | BUG=12258 TEST=unittests Review URL: http://codereview.chromium.org/140015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18961 0039d316-1c4b-4281-b951-d872f2087c98
* Handle proxy corruption including nesting of compressino algorithmsjar@chromium.org2009-06-226-80/+267
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Vodaphone (UK) Mobile Broadband appears to be providing an extra level of gzip compression, at the same time as it discards the content encoding "sdch,gzip" and replaces it with "gzip." The previous approach for handling a missing "sdch" content encoding statement from a server that *probably* was trying to send encoded content, was to replace the (probably) garbage content encoding with tentative decodings for both gzip and sdch. That approach was not sufficient for the resulting double-gzip encoding that Vodaphone provided :-(. This fix leaves the existing content encodings (such as Vodaphone's solo "gzip"), and adds the tentative decodings (gzip plus sdch). Hence we translate received content encodings (when we know we requested an SDCH response by including an applicable dictionary) as follows: "sdch,gzip" unchanged. This is perfect. "" ==> "Tent_sdch, Tent_gzip" "gzip" ==> "Tent_sdch, Test_gzip, gzip" Note that the TENTATIVE_gzip is a sniffing gzip, that can turn into an identity (no-op) filter if it can't find a gzip header. By continuing to use a tentative SDCH, it is possible for the SDCH filter to make error recovery decision, and to record stats on this case. In addition, I've changed the error recovery approach in the SDCH filter to be ultra conservative. If there is ANY unrecoverable error in a response to an SDCH request, then we will blacklist the host of the URL. Recoverable errors are where the SDCH is fully functional, and decodes its data using the dictionary. The test cases added focus on the double gzip cases, as observed in Vodaphone (UK) Mobile Broadband. BUG=13606 r=huanr Review URL: http://codereview.chromium.org/140037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18936 0039d316-1c4b-4281-b951-d872f2087c98
* Add "load_states.h" to net.gyp, since it was missing.ericroman@google.com2009-06-221-0/+1
| | | | | | | | | | BUG=none TEST=none TBR=wtc Review URL: http://codereview.chromium.org/141054 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18932 0039d316-1c4b-4281-b951-d872f2087c98
* Remove some unused files.ericroman@google.com2009-06-223-160/+0
| | | | | | | BUG=b/1483703 Review URL: http://codereview.chromium.org/132046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18929 0039d316-1c4b-4281-b951-d872f2087c98
* Don't put CredHandleClass in std::map directly becausewtc@chromium.org2009-06-201-7/+16
| | | | | | | | | | | | | std::map may copy an entry to a new address while resizing, which invokes the destructor on the old entry and invalidates its address. R=eroman BUG=http://crbug.com/318 TEST=none Review URL: http://codereview.chromium.org/141011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18879 0039d316-1c4b-4281-b951-d872f2087c98
* Implement the backend of SSL client authentication forwtc@chromium.org2009-06-194-34/+220
| | | | | | | | | | | | | | | | | Windows. Create Schannel SSPI CredHandles with certificates for SSL client authentication. Remember the client certificates that the user selected so that we don't ask the user again and again. R=rvargas,eroman BUG=http://crbug.com/318 TEST=none Review URL: http://codereview.chromium.org/131086 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18841 0039d316-1c4b-4281-b951-d872f2087c98
* Comments added to SSL unit tests.jrg@chromium.org2009-06-192-0/+35
| | | | | | Review URL: http://codereview.chromium.org/132081 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18835 0039d316-1c4b-4281-b951-d872f2087c98
* Linux: Fallback to SSL if server closes early during TLS handshake.willchan@chromium.org2009-06-191-1/+8
| | | | | | | | | BUG=http://crbug.com/14092 TEST=See bug for example TLS-intolerant server. Review URL: http://codereview.chromium.org/131085 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18830 0039d316-1c4b-4281-b951-d872f2087c98
* Fix problem with how HttpResponseHeaders::Update() copies headers -- it ↵ericroman@google.com2009-06-192-2/+15
| | | | | | | | | | | assumed the value range ended in a '\0'. BUG=14220 TEST=HttpResponseHeadersTest.Update Review URL: http://codereview.chromium.org/132042 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18774 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: First pass to add support for sparse entries.rvargas@google.com2009-06-1814-14/+1603
| | | | | | | | | | | | | Adding Read/Write support. BUG=12258 TEST=unittests. original review: http://codereview.chromium.org/126179 Review URL: http://codereview.chromium.org/132031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18772 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor so checking for number error is done by ParseChunkSize() rather ↵ericroman@google.com2009-06-182-6/+12
| | | | | | | | than the caller of ParseChunkSize(). Review URL: http://codereview.chromium.org/132037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18768 0039d316-1c4b-4281-b951-d872f2087c98
* Add a simple cache of certificates for SSL client authentication.wtc@chromium.org2009-06-186-2/+167
| | | | | | | | | | | | | It is based on FtpAuthCache and will be used in similar ways. The the only difference is that the authentication data is a certificate rather than username and password. R=eroman BUG=http://crbug.com/318 TEST=new unit tests. Review URL: http://codereview.chromium.org/132004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18735 0039d316-1c4b-4281-b951-d872f2087c98
* Revert cl 18723.rvargas@google.com2009-06-1814-1593/+14
| | | | | | | TBR=nsylvain git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18726 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: First pass to add support for sparse entries.rvargas@google.com2009-06-1814-14/+1593
| | | | | | | | | | | | Adding Read/Write support. BUG=12258 TEST=unittests. Review URL: http://codereview.chromium.org/126179 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18723 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crashes stemming from ClientSocketPoolBase::ReleaseSocket().willchan@chromium.org2009-06-183-20/+61
| | | | | | | | | BUG=http://crbug.com/13908 TEST=Go to a page that loads lots of content from the same host, and then triggers a redirect (which will cancel the requests). A good example is http://photo.sora.net/album/theme/index.php. Unittest coverage provided in TCPClientSocketPoolTest.CancelActiveRequestWithPendingRequests. Review URL: http://codereview.chromium.org/131023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18718 0039d316-1c4b-4281-b951-d872f2087c98
* Revert r18683: "Add more CHECKs to ClientSocketPoolBase."willchan@chromium.org2009-06-181-17/+11
| | | | | | | | Looks like it might have broken block-test.html somehow. Review URL: http://codereview.chromium.org/131020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18688 0039d316-1c4b-4281-b951-d872f2087c98
* Improve chunked encoding parsing.abarth@chromium.org2009-06-182-1/+9
| | | | | | | | | | | | R=abarth BUG=14508 TEST=HttpChunkedDecoderTest.ExcessiveChunkLen Patch contributed by Chris Evans. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18687 0039d316-1c4b-4281-b951-d872f2087c98
* Add more CHECKs to ClientSocketPoolBase.willchan@chromium.org2009-06-181-11/+17
| | | | | | | | BUG=http://crbug.com/14395 Review URL: http://codereview.chromium.org/131017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18683 0039d316-1c4b-4281-b951-d872f2087c98
* Use factories for ConnectingSockets.willchan@chromium.org2009-06-182-33/+93
| | | | | | | | | | This breaks the dependency between ClientSocketPoolBase and the specific ConnectingSocket. The derived class of ClientSocketPool passes in a ConnectingSocketFactory to ClientSocketPoolBase. BUG=http://crbug.com/13289 Review URL: http://codereview.chromium.org/125282 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18681 0039d316-1c4b-4281-b951-d872f2087c98
* Add CHECKs to keep the socket counts in sync.willchan@chromium.org2009-06-172-3/+42
| | | | | | | | | A full chromebot run on 189.0 revealed them getting out of sync, so this should reveal where they get out of sync. BUG=http://crbug.com/14395. Review URL: http://codereview.chromium.org/125276 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18669 0039d316-1c4b-4281-b951-d872f2087c98
* Move most of the code for TCPClientSocketPool into ClientSocketPoolBase for ↵willchan@chromium.org2009-06-174-59/+150
| | | | | | | | | | | sharing. Also rename idle_socket_count() to IdleSocketCount in ClientSocketPool and derived classes, since it's virtual. BUG=http://crbug.com/13289 Review URL: http://codereview.chromium.org/125238 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18622 0039d316-1c4b-4281-b951-d872f2087c98
* Compile fetch_server on POSIX.phajdan.jr@chromium.org2009-06-175-41/+55
| | | | | | | | | | | | 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
* Compile fetch_client on all platforms and add a TODO(port) for fetch_server.phajdan.jr@chromium.org2009-06-171-14/+15
| | | | | | Review URL: http://codereview.chromium.org/126210 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18606 0039d316-1c4b-4281-b951-d872f2087c98
* Reorder URLRequest members so URLRequestContext lasts longer than URLRequestJob.willchan@chromium.org2009-06-171-3/+3
| | | | | | | | BUG=http://crbug.com/14231 Review URL: http://codereview.chromium.org/125235 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18591 0039d316-1c4b-4281-b951-d872f2087c98
* Re-land final subset of r18520.ericroman@google.com2009-06-172-10/+14
| | | | | | | | | | | | The original code review that this belongs to is: <http://codereview.chromium.org/125171>. (BUG=14138) The original was backed out because of a valgrind linux error (BUG=14218), so I relanded it in smaller chunks to see at which point problem happens. This differs from the original, in that I have changed the unit-test to no longer use ScopedMapper + WaitingMapper, which I believe was the source of a race. Review URL: http://codereview.chromium.org/125232 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18587 0039d316-1c4b-4281-b951-d872f2087c98
* Reorder members in URLRequestHttpJob to get correct destruction order.willchan@chromium.org2009-06-172-6/+7
| | | | | | | | BUG=http://crbug.com/14231 Review URL: http://codereview.chromium.org/126257 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18586 0039d316-1c4b-4281-b951-d872f2087c98
* Re-land second-to-last subset of r18520 (now everything is relanded except ↵ericroman@google.com2009-06-173-3/+17
| | | | | | | | | | | | notification of cancellation during destruction). The original code review that this belongs to is:<http://codereview.chromium.org/125171>. (BUG=14138) The original was backed out because of a valgrind linux error (BUG=14218), so I am now re-landing in smaller chunks to identify where the problem resides Review URL: http://codereview.chromium.org/126254 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18583 0039d316-1c4b-4281-b951-d872f2087c98
* Re-land another subset of r18520.ericroman@google.com2009-06-174-16/+121
| | | | | | | | | | | | This particular subset should be a no-op: It adds an unused interface method (OnResolutionCancelled), and an unused test (CancelObserver), and lastly renames Cancel --> MarkAsCanceled(). The code in "dns_global.cc" is also unused since it is unreachable. The original code review that this belongs to is:<http://codereview.chromium.org/125171>. (BUG=14138) The original was backed out because of a valgrind linux error (BUG=14218), so I am now re-landing in smaller chunks to identify where the problem resides. Review URL: http://codereview.chromium.org/126253 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18581 0039d316-1c4b-4281-b951-d872f2087c98
* Re-land a subset of r18520.ericroman@google.com2009-06-172-14/+35
| | | | | | | | | | | | | | | | The original code review for this change was: <http://codereview.chromium.org/125171> The particular subset is the third bullet point in original description: * Fix a bug where completion notification wasn't being sent when the response was cached. (BUG=14188) Note that the original was rolled-back because something was upsetting valgrind (BUG=14218). Review URL: http://codereview.chromium.org/125227 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18579 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 18520.ericroman@google.com2009-06-175-180/+28
| | | | | | | | | | | | | | The original code review for this change was: <http://codereview.chromium.org/125171> It is being reverted because it seems to have caused a valgrind on linux regression: <http://crbug.com14218> BUG=14218,14138,14188 Review URL: http://codereview.chromium.org/126248 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18574 0039d316-1c4b-4281-b951-d872f2087c98
* Fixing a bug in HttpResponseHeaders.GetContentRangehclam@chromium.org2009-06-162-3/+14
| | | | | | | | | The code has a glitch in handling LWS near to the "bytes" token. BUG=14216 Review URL: http://codereview.chromium.org/126229 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18556 0039d316-1c4b-4281-b951-d872f2087c98
* Temporarily disable a test which appears to be causing valgrind errors.eroman@chromium.org2009-06-161-1/+2
| | | | | | | | | | The cause of the problem is not fully understood yet, suppressing to remove noise from the tree. BUG=14218 Review URL: http://codereview.chromium.org/126236 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18553 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor ConnectingSocket out of TCPClientSocketPool.willchan@chromium.org2009-06-162-111/+182
| | | | | | | | | BUG=http://crbug.com/13289 TEST=covered by existing tcp_client_socket_pool_unittest.cc tests. Review URL: http://codereview.chromium.org/125170 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18538 0039d316-1c4b-4281-b951-d872f2087c98
* * Add an OnCancelResolution() notifier to HostResolver::Observer, so ↵ericroman@google.com2009-06-164-27/+178
| | | | | | | | | | | | | | | observers can tell when a request has been cancelled. * Use OnCancelResolution() in DNS prefetcher observer, to avoid leaking entries in the |resolution| table when requests are cancelled. (BUG=14138) * Fix a bug where completion notification wasn't being sent when the response was cached. (BUG=14188) BUG=14138,14188 TEST=HostResolverTest.CancellationObserver, HostResolverTest.Observer Review URL: http://codereview.chromium.org/125171 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18520 0039d316-1c4b-4281-b951-d872f2087c98
* Make HttpNetworkLayer tests network-independent.phajdan.jr@chromium.org2009-06-164-31/+51
| | | | | | | | | | | | 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
* Bypass the host cache when you refresh a page.ericroman@google.com2009-06-162-6/+53
| | | | | | | | | BUG=13163 TEST=HttpNetworkTransactionTest.BypassHostCacheOnRefresh, HostResolverTest.BypassCache Review URL: http://codereview.chromium.org/125154 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18474 0039d316-1c4b-4281-b951-d872f2087c98
* Take 2. Make TCPClientSocketPool own the ConnectingSockets.willchan@chromium.org2009-06-155-59/+79
| | | | | | | | | | | Fix connecting_sockets_map_ to get updated before running callback. BUG=none TEST=TCPClientSocketPoolTest.RequestTwice BUG=http://crbug.com/13952 Review URL: http://codereview.chromium.org/126168 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18453 0039d316-1c4b-4281-b951-d872f2087c98