| Index: net/http/http_auth_cache.h
|
| ===================================================================
|
| --- net/http/http_auth_cache.h (revision 71164)
|
| +++ net/http/http_auth_cache.h (working copy)
|
| @@ -13,6 +13,7 @@
|
| #include "base/ref_counted.h"
|
| #include "base/string16.h"
|
| #include "googleurl/src/gurl.h"
|
| +#include "net/http/http_auth.h"
|
|
|
| namespace net {
|
|
|
| @@ -42,10 +43,11 @@
|
| // scheme |scheme|.
|
| // |origin| - the {scheme, host, port} of the server.
|
| // |realm| - case sensitive realm string.
|
| - // |scheme| - case sensitive authentication scheme, should be lower-case.
|
| + // |scheme| - the authentication scheme (i.e. basic, negotiate).
|
| // returns - the matched entry or NULL.
|
| - Entry* Lookup(const GURL& origin, const std::string& realm,
|
| - const std::string& scheme);
|
| + Entry* Lookup(const GURL& origin,
|
| + const std::string& realm,
|
| + HttpAuth::Scheme scheme);
|
|
|
| // Find the entry on server |origin| whose protection space includes
|
| // |path|. This uses the assumption in RFC 2617 section 2 that deeper
|
| @@ -62,7 +64,7 @@
|
| // paths list.
|
| // |origin| - the {scheme, host, port} of the server.
|
| // |realm| - the auth realm for the challenge.
|
| - // |scheme| - the authentication scheme for the challenge.
|
| + // |scheme| - the authentication scheme (i.e. basic, negotiate).
|
| // |username| - login information for the realm.
|
| // |password| - login information for the realm.
|
| // |path| - absolute path for a resource contained in the protection
|
| @@ -70,7 +72,7 @@
|
| // returns - the entry that was just added/updated.
|
| Entry* Add(const GURL& origin,
|
| const std::string& realm,
|
| - const std::string& scheme,
|
| + HttpAuth::Scheme scheme,
|
| const std::string& auth_challenge,
|
| const string16& username,
|
| const string16& password,
|
| @@ -80,13 +82,13 @@
|
| // if one exists AND if the cached identity matches (|username|, |password|).
|
| // |origin| - the {scheme, host, port} of the server.
|
| // |realm| - case sensitive realm string.
|
| - // |scheme| - authentication scheme
|
| + // |scheme| - the authentication scheme (i.e. basic, negotiate).
|
| // |username| - condition to match.
|
| // |password| - condition to match.
|
| // returns - true if an entry was removed.
|
| bool Remove(const GURL& origin,
|
| const std::string& realm,
|
| - const std::string& scheme,
|
| + HttpAuth::Scheme scheme,
|
| const string16& username,
|
| const string16& password);
|
|
|
| @@ -97,7 +99,7 @@
|
| // cache, false otherwise.
|
| bool UpdateStaleChallenge(const GURL& origin,
|
| const std::string& realm,
|
| - const std::string& scheme,
|
| + HttpAuth::Scheme scheme,
|
| const std::string& auth_challenge);
|
|
|
| private:
|
| @@ -119,8 +121,8 @@
|
| return realm_;
|
| }
|
|
|
| - // The authentication scheme string of the challenge
|
| - const std::string scheme() const {
|
| + // The authentication scheme of the challenge.
|
| + const HttpAuth::Scheme scheme() const {
|
| return scheme_;
|
| }
|
|
|
| @@ -161,10 +163,10 @@
|
| // Returns true if |dir| is contained within the realm's protection space.
|
| bool HasEnclosingPath(const std::string& dir);
|
|
|
| - // |origin_| contains the {scheme, host, port} of the server.
|
| + // |origin_| contains the {protocol, host, port} of the server.
|
| GURL origin_;
|
| std::string realm_;
|
| - std::string scheme_;
|
| + HttpAuth::Scheme scheme_;
|
|
|
| // Identity.
|
| std::string auth_challenge_;
|
|
|