OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef NET_HTTP_HTTP_NETWORK_TRANSACTION_H_ | 5 #ifndef NET_HTTP_HTTP_NETWORK_TRANSACTION_H_ |
6 #define NET_HTTP_HTTP_NETWORK_TRANSACTION_H_ | 6 #define NET_HTTP_HTTP_NETWORK_TRANSACTION_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 // ResetStateForRestart. Sets |next_state_| appropriately. | 228 // ResetStateForRestart. Sets |next_state_| appropriately. |
229 void DidDrainBodyForAuthRestart(bool keep_alive); | 229 void DidDrainBodyForAuthRestart(bool keep_alive); |
230 | 230 |
231 // Resets the members of the transaction so it can be restarted. | 231 // Resets the members of the transaction so it can be restarted. |
232 void ResetStateForRestart(); | 232 void ResetStateForRestart(); |
233 | 233 |
234 // Resets the members of the transaction, except |stream_|, which needs | 234 // Resets the members of the transaction, except |stream_|, which needs |
235 // to be maintained for multi-round auth. | 235 // to be maintained for multi-round auth. |
236 void ResetStateForAuthRestart(); | 236 void ResetStateForAuthRestart(); |
237 | 237 |
| 238 // Records metrics relating to SSL fallbacks. |
| 239 void RecordSSLFallbackMetrics(); |
| 240 |
238 // Returns true if we should try to add a Proxy-Authorization header | 241 // Returns true if we should try to add a Proxy-Authorization header |
239 bool ShouldApplyProxyAuth() const; | 242 bool ShouldApplyProxyAuth() const; |
240 | 243 |
241 // Returns true if we should try to add an Authorization header. | 244 // Returns true if we should try to add an Authorization header. |
242 bool ShouldApplyServerAuth() const; | 245 bool ShouldApplyServerAuth() const; |
243 | 246 |
244 // Handles HTTP status code 401 or 407. | 247 // Handles HTTP status code 401 or 407. |
245 // HandleAuthChallenge() returns a network error code, or OK on success. | 248 // HandleAuthChallenge() returns a network error code, or OK on success. |
246 // May update |pending_auth_target_| or |response_.auth_challenge|. | 249 // May update |pending_auth_target_| or |response_.auth_challenge|. |
247 int HandleAuthChallenge(); | 250 int HandleAuthChallenge(); |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 BeforeProxyHeadersSentCallback before_proxy_headers_sent_callback_; | 336 BeforeProxyHeadersSentCallback before_proxy_headers_sent_callback_; |
334 | 337 |
335 ConnectionAttempts connection_attempts_; | 338 ConnectionAttempts connection_attempts_; |
336 | 339 |
337 DISALLOW_COPY_AND_ASSIGN(HttpNetworkTransaction); | 340 DISALLOW_COPY_AND_ASSIGN(HttpNetworkTransaction); |
338 }; | 341 }; |
339 | 342 |
340 } // namespace net | 343 } // namespace net |
341 | 344 |
342 #endif // NET_HTTP_HTTP_NETWORK_TRANSACTION_H_ | 345 #endif // NET_HTTP_HTTP_NETWORK_TRANSACTION_H_ |
OLD | NEW |