| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_STREAM_FACTORY_H_ | 5 #ifndef NET_HTTP_STREAM_FACTORY_H_ |
| 6 #define NET_HTTP_STREAM_FACTORY_H_ | 6 #define NET_HTTP_STREAM_FACTORY_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/ref_counted.h" | 10 #include "base/ref_counted.h" |
| 11 #include "net/base/completion_callback.h" | 11 #include "net/base/completion_callback.h" |
| 12 #include "net/base/load_states.h" | 12 #include "net/base/load_states.h" |
| 13 | 13 |
| 14 namespace net { | 14 namespace net { |
| 15 | 15 |
| 16 class AuthChallengeInfo; |
| 16 class BoundNetLog; | 17 class BoundNetLog; |
| 17 class HostPortPair; | 18 class HostPortPair; |
| 18 class HttpAlternateProtocols; | 19 class HttpAlternateProtocols; |
| 19 class HttpAuthController; | 20 class HttpAuthController; |
| 20 class HttpNetworkSession; | 21 class HttpNetworkSession; |
| 21 class HttpResponseInfo; | 22 class HttpResponseInfo; |
| 22 class HttpStream; | 23 class HttpStream; |
| 23 class ProxyInfo; | 24 class ProxyInfo; |
| 24 class SSLCertRequestInfo; | 25 class SSLCertRequestInfo; |
| 25 class SSLInfo; | 26 class SSLInfo; |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 // callback. | 64 // callback. |
| 64 virtual void OnNeedsProxyAuth(const HttpResponseInfo& proxy_response, | 65 virtual void OnNeedsProxyAuth(const HttpResponseInfo& proxy_response, |
| 65 HttpAuthController* auth_controller) = 0; | 66 HttpAuthController* auth_controller) = 0; |
| 66 | 67 |
| 67 // This is the failure for SSL Client Auth | 68 // This is the failure for SSL Client Auth |
| 68 // Ownership of |cert_info| is retained by the StreamRequest. The delegate | 69 // Ownership of |cert_info| is retained by the StreamRequest. The delegate |
| 69 // may take a reference if it needs the cert_info beyond the lifetime of | 70 // may take a reference if it needs the cert_info beyond the lifetime of |
| 70 // this callback. | 71 // this callback. |
| 71 virtual void OnNeedsClientAuth(SSLCertRequestInfo* cert_info) = 0; | 72 virtual void OnNeedsClientAuth(SSLCertRequestInfo* cert_info) = 0; |
| 72 | 73 |
| 74 // Called when we need to provide TLS client login credentials. |
| 75 virtual void OnNeedsTLSLogin(AuthChallengeInfo* login_info) = 0; |
| 76 |
| 73 // This is the failure of the CONNECT request through an HTTPS proxy. | 77 // This is the failure of the CONNECT request through an HTTPS proxy. |
| 74 // Headers can be read from |response_info|, while the body can be read | 78 // Headers can be read from |response_info|, while the body can be read |
| 75 // from |stream|. | 79 // from |stream|. |
| 76 // Ownership of |stream| is transferred to the delegate. | 80 // Ownership of |stream| is transferred to the delegate. |
| 77 virtual void OnHttpsProxyTunnelResponse( | 81 virtual void OnHttpsProxyTunnelResponse( |
| 78 const HttpResponseInfo& response_info, HttpStream* stream) = 0; | 82 const HttpResponseInfo& response_info, HttpStream* stream) = 0; |
| 79 }; | 83 }; |
| 80 | 84 |
| 81 virtual ~StreamRequest() {} | 85 virtual ~StreamRequest() {} |
| 82 | 86 |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 147 const std::string& alternate_protocol_str, | 151 const std::string& alternate_protocol_str, |
| 148 const HostPortPair& http_host_port_pair) = 0; | 152 const HostPortPair& http_host_port_pair) = 0; |
| 149 | 153 |
| 150 virtual GURL ApplyHostMappingRules(const GURL& url, | 154 virtual GURL ApplyHostMappingRules(const GURL& url, |
| 151 HostPortPair* endpoint) = 0; | 155 HostPortPair* endpoint) = 0; |
| 152 }; | 156 }; |
| 153 | 157 |
| 154 } // namespace net | 158 } // namespace net |
| 155 | 159 |
| 156 #endif // NET_HTTP_STREAM_FACTORY_H_ | 160 #endif // NET_HTTP_STREAM_FACTORY_H_ |
| OLD | NEW |