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

Unified Diff: net/base/auth.h

Issue 8015004: webRequest.onAuthRequired listeners can provide authentication credentials. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 9 years, 3 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/base/auth.h
diff --git a/net/base/auth.h b/net/base/auth.h
index 51f8db95388cd699b10e90a4effd6f76f321e0e9..6dcd913a739947e065aa07c76c03e9f1b0b22cb0 100644
--- a/net/base/auth.h
+++ b/net/base/auth.h
@@ -65,6 +65,31 @@ class AuthData : public base::RefCountedThreadSafe<AuthData> {
~AuthData();
};
+// Authentication Credentials for an authentication credentials.
+class NET_EXPORT AuthCredentials {
+ public:
+ AuthCredentials();
+ ~AuthCredentials();
+
+ // |is_valid| is true if the username and password have been set. Since
+ // username and/or password may be empty, this is needed to differentiate
+ // that case.
+ bool is_valid;
+
+ // The username to provide, possibly empty. This should be ASCII only to
+ // minimize compatibility problems, but arbitrary UTF-16 strings are allowed
+ // and will be attempted.
+ string16 username;
+
+ // The password to provide, possibly empty. This should be ASCII only to
+ // minimize compatibility problems, but arbitrary UTF-16 strings are allowed
+ // and will be attempted.
+ string16 password;
+
+ // Intentionally allowing the implicit copy constructor and assignment
+ // operators.
+};
+
} // namespace net
#endif // NET_BASE_AUTH_H__

Powered by Google App Engine
This is Rietveld 408576698