| Index: components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h
|
| diff --git a/components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h b/components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h
|
| index 17b497a815fa17af9172003960978cd3b7706576..992b8b66e5e5d04435c02800d18ec686866f2c43 100644
|
| --- a/components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h
|
| +++ b/components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h
|
| @@ -82,9 +82,15 @@ class DataReductionProxyAuthRequestHandler {
|
| FRIEND_TEST_ALL_PREFIXES(DataReductionProxyAuthRequestHandlerTest,
|
| AuthHashForSalt);
|
|
|
| - void InitAuthentication(
|
| - const std::string& session,
|
| - const std::string& credentials);
|
| + // Stores the supplied key and sets up credentials suitable for authenticating
|
| + // with the data reduction proxy.
|
| + void InitAuthentication(const std::string& key);
|
| +
|
| + // Generates a session ID and credentials suitable for authenticating with
|
| + // the data reduction proxy.
|
| + void ComputeCredentials(const base::Time& now,
|
| + std::string* session,
|
| + std::string* credentials);
|
|
|
| // Authentication state.
|
| std::string key_;
|
| @@ -98,6 +104,10 @@ class DataReductionProxyAuthRequestHandler {
|
| std::string client_;
|
| std::string version_;
|
|
|
| + // The last time the session was updated. Used to ensure that a session is
|
| + // never used for more than twenty-four hours.
|
| + base::Time last_update_time_;
|
| +
|
| DataReductionProxyParams* data_reduction_proxy_params_;
|
|
|
| scoped_refptr<base::SingleThreadTaskRunner> network_task_runner_;
|
|
|