Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1087)

Unified Diff: net/http/http_network_transaction.cc

Issue 8340026: Use AuthCredentials throughout the network stack instead of username/password. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Reduce password zapping Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/http/http_network_transaction.cc
diff --git a/net/http/http_network_transaction.cc b/net/http/http_network_transaction.cc
index c66f0f3865b3e1f3b1cdbed86d062590c5a2aa9c..7c2b2bb07ea188e4264d5b7b3eca57578818c62f 100644
--- a/net/http/http_network_transaction.cc
+++ b/net/http/http_network_transaction.cc
@@ -203,10 +203,8 @@ int HttpNetworkTransaction::RestartWithCertificate(
return rv;
}
-int HttpNetworkTransaction::RestartWithAuth(
- const string16& username,
- const string16& password,
- OldCompletionCallback* callback) {
+int HttpNetworkTransaction::RestartWithAuth(const AuthCredentials& credentials,
+ OldCompletionCallback* callback) {
HttpAuth::Target target = pending_auth_target_;
if (target == HttpAuth::AUTH_NONE) {
NOTREACHED();
@@ -214,7 +212,7 @@ int HttpNetworkTransaction::RestartWithAuth(
}
pending_auth_target_ = HttpAuth::AUTH_NONE;
- auth_controllers_[target]->ResetAuth(username, password);
+ auth_controllers_[target]->ResetAuth(credentials);
DCHECK(user_callback_ == NULL);
@@ -226,7 +224,7 @@ int HttpNetworkTransaction::RestartWithAuth(
DCHECK(stream_request_ != NULL);
auth_controllers_[target] = NULL;
ResetStateForRestart();
- rv = stream_request_->RestartTunnelWithProxyAuth(username, password);
+ rv = stream_request_->RestartTunnelWithProxyAuth(credentials);
} else {
// In this case, we've gathered credentials for the server or the proxy
// but it is not during the tunneling phase.

Powered by Google App Engine
This is Rietveld 408576698