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

Unified Diff: net/ftp/ftp_auth_cache.h

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/ftp/ftp_auth_cache.h
diff --git a/net/ftp/ftp_auth_cache.h b/net/ftp/ftp_auth_cache.h
index 6281f9dcffe1c3015adacbfe897a1aead8d7cf9a..5c6d7d5c6acb92fdb75af2dca2ef1d2809a7a1cc 100644
--- a/net/ftp/ftp_auth_cache.h
+++ b/net/ftp/ftp_auth_cache.h
@@ -8,8 +8,8 @@
#include <list>
-#include "base/string16.h"
#include "googleurl/src/gurl.h"
+#include "net/base/auth.h"
#include "net/base/net_export.h"
namespace net {
@@ -28,13 +28,11 @@ class NET_EXPORT_PRIVATE FtpAuthCache {
static const size_t kMaxEntries;
struct Entry {
- Entry(const GURL& origin, const string16& username,
- const string16& password);
+ Entry(const GURL& origin, const AuthCredentials& credentials);
~Entry();
const GURL origin;
- string16 username;
- string16 password;
+ AuthCredentials credentials;
};
FtpAuthCache();
@@ -46,13 +44,11 @@ class NET_EXPORT_PRIVATE FtpAuthCache {
// Add an entry for |origin| to the cache (consisting of |username| and
// |password|). If there is already an entry for |origin|, it will be
// overwritten.
- void Add(const GURL& origin, const string16& username,
- const string16& password);
+ void Add(const GURL& origin, const AuthCredentials& credentials);
// Remove the entry for |origin| from the cache, if one exists and matches
// |username| and |password|.
- void Remove(const GURL& origin, const string16& username,
- const string16& password);
+ void Remove(const GURL& origin, const AuthCredentials& credentials);
private:
typedef std::list<Entry> EntryList;
« no previous file with comments | « net/base/zap.cc ('k') | net/ftp/ftp_auth_cache.cc » ('j') | net/ftp/ftp_transaction.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698