OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/loader/resource_loader.h" | 5 #include "content/browser/loader/resource_loader.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
10 #include "base/profiler/scoped_tracker.h" | 10 #include "base/profiler/scoped_tracker.h" |
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
409 } | 409 } |
410 | 410 |
411 void ResourceLoader::ContinueSSLRequest() { | 411 void ResourceLoader::ContinueSSLRequest() { |
412 DCHECK_CURRENTLY_ON(BrowserThread::IO); | 412 DCHECK_CURRENTLY_ON(BrowserThread::IO); |
413 | 413 |
414 DVLOG(1) << "ContinueSSLRequest() url: " << request_->url().spec(); | 414 DVLOG(1) << "ContinueSSLRequest() url: " << request_->url().spec(); |
415 | 415 |
416 request_->ContinueDespiteLastError(); | 416 request_->ContinueDespiteLastError(); |
417 } | 417 } |
418 | 418 |
419 void ResourceLoader::ContinueWithCertificate(net::X509Certificate* cert) { | 419 void ResourceLoader::ContinueWithCertificate(net::X509Certificate* cert, |
| 420 net::SSLPrivateKey* private_key) { |
420 DCHECK(ssl_client_auth_handler_); | 421 DCHECK(ssl_client_auth_handler_); |
421 ssl_client_auth_handler_.reset(); | 422 ssl_client_auth_handler_.reset(); |
422 request_->ContinueWithCertificate(cert); | 423 request_->ContinueWithCertificate(cert, private_key); |
423 } | 424 } |
424 | 425 |
425 void ResourceLoader::CancelCertificateSelection() { | 426 void ResourceLoader::CancelCertificateSelection() { |
426 DCHECK(ssl_client_auth_handler_); | 427 DCHECK(ssl_client_auth_handler_); |
427 ssl_client_auth_handler_.reset(); | 428 ssl_client_auth_handler_.reset(); |
428 request_->CancelWithError(net::ERR_SSL_CLIENT_AUTH_CERT_NEEDED); | 429 request_->CancelWithError(net::ERR_SSL_CLIENT_AUTH_CERT_NEEDED); |
429 } | 430 } |
430 | 431 |
431 void ResourceLoader::Resume() { | 432 void ResourceLoader::Resume() { |
432 DCHECK(!is_transferring_); | 433 DCHECK(!is_transferring_); |
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
697 case net::URLRequestStatus::FAILED: | 698 case net::URLRequestStatus::FAILED: |
698 status = STATUS_UNDEFINED; | 699 status = STATUS_UNDEFINED; |
699 break; | 700 break; |
700 } | 701 } |
701 | 702 |
702 UMA_HISTOGRAM_ENUMERATION("Net.Prefetch.Pattern", status, STATUS_MAX); | 703 UMA_HISTOGRAM_ENUMERATION("Net.Prefetch.Pattern", status, STATUS_MAX); |
703 } | 704 } |
704 } | 705 } |
705 | 706 |
706 } // namespace content | 707 } // namespace content |
OLD | NEW |