Avi Drissman | 6459548 | 2022-09-14 20:52:29 | [diff] [blame] | 1 | // Copyright 2012 The Chromium Authors |
license.bot | bf09a50 | 2008-08-24 00:55:55 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 4 | |
[email protected] | f7984fc6 | 2009-06-22 23:26:44 | [diff] [blame] | 5 | #ifndef NET_SOCKET_CLIENT_SOCKET_HANDLE_H_ |
| 6 | #define NET_SOCKET_CLIENT_SOCKET_HANDLE_H_ |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 7 | |
danakj | 655b66c | 2016-04-16 00:51:38 | [diff] [blame] | 8 | #include <memory> |
David Benjamin | 0c61616 | 2018-03-23 22:15:47 | [diff] [blame] | 9 | #include <utility> |
[email protected] | 7b822b2b | 2008-08-05 00:15:45 | [diff] [blame] | 10 | |
Hans Wennborg | 0cb546b | 2020-06-23 18:00:09 | [diff] [blame] | 11 | #include "base/check.h" |
Avi Drissman | 41c4a41 | 2023-01-11 22:45:37 | [diff] [blame^] | 12 | #include "base/functional/bind.h" |
Keishi Hattori | 0e45c02 | 2021-11-27 09:25:52 | [diff] [blame] | 13 | #include "base/memory/raw_ptr.h" |
Lei Zhang | 58a108245 | 2022-11-08 04:23:20 | [diff] [blame] | 14 | #include "base/memory/scoped_refptr.h" |
[email protected] | f002abb | 2013-06-28 02:30:21 | [diff] [blame] | 15 | #include "base/time/time.h" |
ttuttle | 1f2d7e9 | 2015-04-28 16:17:47 | [diff] [blame] | 16 | #include "net/base/ip_endpoint.h" |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 17 | #include "net/base/load_states.h" |
[email protected] | 034df0f3 | 2013-01-07 23:17:48 | [diff] [blame] | 18 | #include "net/base/load_timing_info.h" |
[email protected] | d80a432 | 2009-08-14 07:07:49 | [diff] [blame] | 19 | #include "net/base/net_errors.h" |
[email protected] | 172da1b | 2011-08-12 15:52:26 | [diff] [blame] | 20 | #include "net/base/net_export.h" |
[email protected] | ac790b4 | 2009-12-02 04:31:31 | [diff] [blame] | 21 | #include "net/base/request_priority.h" |
dalyk | edd30d98 | 2019-12-16 15:31:10 | [diff] [blame] | 22 | #include "net/dns/public/resolve_error_info.h" |
mikecirone | f22f981 | 2016-10-04 03:40:19 | [diff] [blame] | 23 | #include "net/log/net_log_source.h" |
| 24 | #include "net/log/net_log_with_source.h" |
[email protected] | d80a432 | 2009-08-14 07:07:49 | [diff] [blame] | 25 | #include "net/socket/client_socket_pool.h" |
ttuttle | 1f2d7e9 | 2015-04-28 16:17:47 | [diff] [blame] | 26 | #include "net/socket/connection_attempts.h" |
[email protected] | 3268023f | 2011-05-05 00:08:10 | [diff] [blame] | 27 | #include "net/socket/stream_socket.h" |
Matt Menke | 39b7c5a | 2019-04-10 19:47:51 | [diff] [blame] | 28 | #include "net/ssl/ssl_cert_request_info.h" |
Anton Bikineev | 068d291 | 2021-05-15 20:43:52 | [diff] [blame] | 29 | #include "third_party/abseil-cpp/absl/types/optional.h" |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 30 | |
| 31 | namespace net { |
| 32 | |
Matt Menke | c1ae1d5 | 2019-04-10 19:28:27 | [diff] [blame] | 33 | class ConnectJob; |
Matt Menke | f09e64c | 2019-04-23 22:16:28 | [diff] [blame] | 34 | struct NetworkTrafficAnnotationTag; |
Paul Jensen | 8d6f87ec | 2018-01-13 00:46:54 | [diff] [blame] | 35 | class SocketTag; |
| 36 | |
[email protected] | 3268023f | 2011-05-05 00:08:10 | [diff] [blame] | 37 | // A container for a StreamSocket. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 38 | // |
Matt Menke | f6edce75 | 2019-03-19 17:21:56 | [diff] [blame] | 39 | // The handle's |group_id| uniquely identifies the origin and type of the |
[email protected] | e1e0626 | 2008-08-06 23:57:07 | [diff] [blame] | 40 | // connection. It is used by the ClientSocketPool to group similar connected |
| 41 | // client socket objects. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 42 | // |
[email protected] | 172da1b | 2011-08-12 15:52:26 | [diff] [blame] | 43 | class NET_EXPORT ClientSocketHandle { |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 44 | public: |
[email protected] | be1a48b | 2011-01-20 00:12:13 | [diff] [blame] | 45 | enum SocketReuseType { |
[email protected] | a19f1c60 | 2009-08-24 21:35:28 | [diff] [blame] | 46 | UNUSED = 0, // unused socket that just finished connecting |
[email protected] | cd27312 | 2009-08-22 21:20:11 | [diff] [blame] | 47 | UNUSED_IDLE, // unused socket that has been idle for awhile |
| 48 | REUSED_IDLE, // previously used socket |
[email protected] | f9d285c | 2009-08-17 19:54:29 | [diff] [blame] | 49 | NUM_TYPES, |
[email protected] | be1a48b | 2011-01-20 00:12:13 | [diff] [blame] | 50 | }; |
[email protected] | f9d285c | 2009-08-17 19:54:29 | [diff] [blame] | 51 | |
[email protected] | a512f598 | 2009-08-18 16:01:06 | [diff] [blame] | 52 | ClientSocketHandle(); |
Peter Boström | 293b134 | 2021-09-22 17:31:43 | [diff] [blame] | 53 | |
| 54 | ClientSocketHandle(const ClientSocketHandle&) = delete; |
| 55 | ClientSocketHandle& operator=(const ClientSocketHandle&) = delete; |
| 56 | |
[email protected] | e1e0626 | 2008-08-06 23:57:07 | [diff] [blame] | 57 | ~ClientSocketHandle(); |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 58 | |
[email protected] | e1e0626 | 2008-08-06 23:57:07 | [diff] [blame] | 59 | // Initializes a ClientSocketHandle object, which involves talking to the |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 60 | // ClientSocketPool to obtain a connected socket, possibly reusing one. This |
| 61 | // method returns either OK or ERR_IO_PENDING. On ERR_IO_PENDING, |priority| |
| 62 | // is used to determine the placement in ClientSocketPool's wait list. |
mmenke | d3641e1 | 2016-01-28 16:06:15 | [diff] [blame] | 63 | // If |respect_limits| is DISABLED, will bypass the wait list, but |priority| |
| 64 | // must also be HIGHEST, if set. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 65 | // |
| 66 | // If this method succeeds, then the socket member will be set to an existing |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 67 | // connected socket if an existing connected socket was available to reuse, |
| 68 | // otherwise it will be set to a new connected socket. Consumers can then |
| 69 | // call is_reused() to see if the socket was reused. If not reusing an |
[email protected] | 2884a46 | 2009-06-15 05:08:42 | [diff] [blame] | 70 | // existing socket, ClientSocketPool may need to establish a new |
[email protected] | d80a432 | 2009-08-14 07:07:49 | [diff] [blame] | 71 | // connection using |socket_params|. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 72 | // |
| 73 | // This method returns ERR_IO_PENDING if it cannot complete synchronously, in |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 74 | // which case the consumer will be notified of completion via |callback|. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 75 | // |
[email protected] | e772db3f | 2010-07-12 18:11:13 | [diff] [blame] | 76 | // If the pool was not able to reuse an existing socket, the new socket |
| 77 | // may report a recoverable error. In this case, the return value will |
| 78 | // indicate an error and the socket member will be set. If it is determined |
| 79 | // that the error is not recoverable, the Disconnect method should be used |
| 80 | // on the socket, so that it does not get reused. |
| 81 | // |
[email protected] | e60e47a | 2010-07-14 03:37:18 | [diff] [blame] | 82 | // A non-recoverable error may set additional state in the ClientSocketHandle |
| 83 | // to allow the caller to determine what went wrong. |
| 84 | // |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 85 | // Init may be called multiple times. |
| 86 | // |
[email protected] | 9e743cd | 2010-03-16 07:03:53 | [diff] [blame] | 87 | // Profiling information for the request is saved to |net_log| if non-NULL. |
Matt Menke | f09e64c | 2019-04-23 22:16:28 | [diff] [blame] | 88 | int Init( |
| 89 | const ClientSocketPool::GroupId& group_id, |
| 90 | scoped_refptr<ClientSocketPool::SocketParams> socket_params, |
Anton Bikineev | 068d291 | 2021-05-15 20:43:52 | [diff] [blame] | 91 | const absl::optional<NetworkTrafficAnnotationTag>& proxy_annotation_tag, |
Matt Menke | f09e64c | 2019-04-23 22:16:28 | [diff] [blame] | 92 | RequestPriority priority, |
| 93 | const SocketTag& socket_tag, |
| 94 | ClientSocketPool::RespectLimits respect_limits, |
| 95 | CompletionOnceCallback callback, |
| 96 | const ClientSocketPool::ProxyAuthCallback& proxy_auth_callback, |
| 97 | ClientSocketPool* pool, |
| 98 | const NetLogWithSource& net_log); |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 99 | |
rdsmith | 29dbad1 | 2017-02-17 02:22:18 | [diff] [blame] | 100 | // Changes the priority of the ClientSocketHandle to the passed value. |
| 101 | // This function is a no-op if |priority| is the same as the current |
| 102 | // priority, of if Init() has not been called since the last time |
| 103 | // the ClientSocketHandle was reset. |
| 104 | void SetPriority(RequestPriority priority); |
| 105 | |
[email protected] | e1e0626 | 2008-08-06 23:57:07 | [diff] [blame] | 106 | // An initialized handle can be reset, which causes it to return to the |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 107 | // un-initialized state. This releases the underlying socket, which in the |
[email protected] | e1e0626 | 2008-08-06 23:57:07 | [diff] [blame] | 108 | // case of a socket that still has an established connection, indicates that |
| 109 | // the socket may be kept alive for use by a subsequent ClientSocketHandle. |
| 110 | // |
| 111 | // NOTE: To prevent the socket from being kept alive, be sure to call its |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 112 | // Disconnect method. This will result in the ClientSocketPool deleting the |
[email protected] | 3268023f | 2011-05-05 00:08:10 | [diff] [blame] | 113 | // StreamSocket. |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 114 | void Reset(); |
| 115 | |
Matt Menke | 7eb405e | 2019-04-25 20:48:21 | [diff] [blame] | 116 | // Like Reset(), but also closes the socket (if there is one) and cancels any |
| 117 | // pending attempt to establish a connection, if the connection attempt is |
| 118 | // still ongoing. |
| 119 | void ResetAndCloseSocket(); |
| 120 | |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 121 | // Used after Init() is called, but before the ClientSocketPool has |
| 122 | // initialized the ClientSocketHandle. |
| 123 | LoadState GetLoadState() const; |
| 124 | |
[email protected] | 51fdc7c | 2012-04-10 19:19:48 | [diff] [blame] | 125 | bool IsPoolStalled() const; |
| 126 | |
[email protected] | 043b68c8 | 2013-08-22 23:41:52 | [diff] [blame] | 127 | // Adds a higher layered pool on top of the socket pool that |socket_| belongs |
| 128 | // to. At most one higher layered pool can be added to a |
| 129 | // ClientSocketHandle at a time. On destruction or reset, automatically |
| 130 | // removes the higher pool if RemoveHigherLayeredPool has not been called. |
| 131 | void AddHigherLayeredPool(HigherLayeredPool* higher_pool); |
[email protected] | 51fdc7c | 2012-04-10 19:19:48 | [diff] [blame] | 132 | |
[email protected] | 043b68c8 | 2013-08-22 23:41:52 | [diff] [blame] | 133 | // Removes a higher layered pool from the socket pool that |socket_| belongs |
| 134 | // to. |higher_pool| must have been added by the above function. |
| 135 | void RemoveHigherLayeredPool(HigherLayeredPool* higher_pool); |
[email protected] | 51fdc7c | 2012-04-10 19:19:48 | [diff] [blame] | 136 | |
xunjieli | 92feb33 | 2017-03-03 17:19:23 | [diff] [blame] | 137 | // Closes idle sockets that are in the same group with |this|. |
Matt Menke | 433de6d | 2020-03-04 00:24:11 | [diff] [blame] | 138 | void CloseIdleSocketsInGroup(const char* net_log_reason_utf8); |
xunjieli | 92feb33 | 2017-03-03 17:19:23 | [diff] [blame] | 139 | |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 140 | // Returns true when Init() has completed successfully. |
[email protected] | 05ea9ff | 2010-07-15 19:08:21 | [diff] [blame] | 141 | bool is_initialized() const { return is_initialized_; } |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 142 | |
[email protected] | 034df0f3 | 2013-01-07 23:17:48 | [diff] [blame] | 143 | // Sets the portion of LoadTimingInfo related to connection establishment, and |
| 144 | // the socket id. |is_reused| is needed because the handle may not have full |
| 145 | // reuse information. |load_timing_info| must have all default values when |
| 146 | // called. Returns false and makes no changes to |load_timing_info| when |
| 147 | // |socket_| is NULL. |
| 148 | bool GetLoadTimingInfo(bool is_reused, |
| 149 | LoadTimingInfo* load_timing_info) const; |
| 150 | |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 151 | // Used by ClientSocketPool to initialize the ClientSocketHandle. |
[email protected] | ebc160063 | 2013-08-28 08:10:05 | [diff] [blame] | 152 | // |
| 153 | // SetSocket() may also be used if this handle is used as simply for |
| 154 | // socket storage (e.g., http://crbug.com/37810). |
danakj | 655b66c | 2016-04-16 00:51:38 | [diff] [blame] | 155 | void SetSocket(std::unique_ptr<StreamSocket> s); |
Matt Menke | c1ae1d5 | 2019-04-10 19:28:27 | [diff] [blame] | 156 | |
| 157 | // Populates several fields of |this| with error-related information from the |
| 158 | // provided completed ConnectJob. Should only be called on ConnectJob failure. |
| 159 | void SetAdditionalErrorState(ConnectJob* connect_job); |
| 160 | |
[email protected] | a34f61ee | 2014-03-18 20:59:49 | [diff] [blame] | 161 | void set_reuse_type(SocketReuseType reuse_type) { reuse_type_ = reuse_type; } |
[email protected] | f9d285c | 2009-08-17 19:54:29 | [diff] [blame] | 162 | void set_idle_time(base::TimeDelta idle_time) { idle_time_ = idle_time; } |
Matt Menke | bf3c767d | 2019-04-15 23:28:24 | [diff] [blame] | 163 | void set_group_generation(int64_t group_generation) { |
| 164 | group_generation_ = group_generation; |
| 165 | } |
[email protected] | e60e47a | 2010-07-14 03:37:18 | [diff] [blame] | 166 | void set_is_ssl_error(bool is_ssl_error) { is_ssl_error_ = is_ssl_error; } |
Matt Menke | 39b7c5a | 2019-04-10 19:47:51 | [diff] [blame] | 167 | void set_ssl_cert_request_info( |
| 168 | scoped_refptr<SSLCertRequestInfo> ssl_cert_request_info) { |
| 169 | ssl_cert_request_info_ = std::move(ssl_cert_request_info); |
[email protected] | 8b49869 | 2010-07-16 17:11:43 | [diff] [blame] | 170 | } |
ttuttle | 1f2d7e9 | 2015-04-28 16:17:47 | [diff] [blame] | 171 | void set_connection_attempts(const ConnectionAttempts& attempts) { |
| 172 | connection_attempts_ = attempts; |
| 173 | } |
dalyk | edd30d98 | 2019-12-16 15:31:10 | [diff] [blame] | 174 | ResolveErrorInfo resolve_error_info() const { return resolve_error_info_; } |
[email protected] | 8b49869 | 2010-07-16 17:11:43 | [diff] [blame] | 175 | |
| 176 | // Only valid if there is no |socket_|. |
| 177 | bool is_ssl_error() const { |
melandory | 1346cde | 2016-06-11 00:42:12 | [diff] [blame] | 178 | DCHECK(!socket_); |
[email protected] | 8b49869 | 2010-07-16 17:11:43 | [diff] [blame] | 179 | return is_ssl_error_; |
| 180 | } |
Matt Menke | faae31a | 2019-04-10 19:45:20 | [diff] [blame] | 181 | |
| 182 | // On an ERR_SSL_CLIENT_AUTH_CERT_NEEDED error, the |cert_request_info| field |
| 183 | // is set. |
Matt Menke | 39b7c5a | 2019-04-10 19:47:51 | [diff] [blame] | 184 | scoped_refptr<SSLCertRequestInfo> ssl_cert_request_info() const { |
| 185 | return ssl_cert_request_info_; |
[email protected] | 8b49869 | 2010-07-16 17:11:43 | [diff] [blame] | 186 | } |
Matt Menke | 39b7c5a | 2019-04-10 19:47:51 | [diff] [blame] | 187 | |
David Benjamin | 95ea6832 | 2022-04-25 19:55:19 | [diff] [blame] | 188 | // If the connection failed, returns the connection attempts made. |
ttuttle | 1f2d7e9 | 2015-04-28 16:17:47 | [diff] [blame] | 189 | const ConnectionAttempts& connection_attempts() { |
| 190 | return connection_attempts_; |
| 191 | } |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 192 | |
[email protected] | 18ccfdb | 2013-08-15 00:13:44 | [diff] [blame] | 193 | StreamSocket* socket() { return socket_.get(); } |
[email protected] | ebc160063 | 2013-08-28 08:10:05 | [diff] [blame] | 194 | |
| 195 | // SetSocket() must be called with a new socket before this handle |
| 196 | // is destroyed if is_initialized() is true. |
danakj | 655b66c | 2016-04-16 00:51:38 | [diff] [blame] | 197 | std::unique_ptr<StreamSocket> PassSocket(); |
[email protected] | ebc160063 | 2013-08-28 08:10:05 | [diff] [blame] | 198 | |
| 199 | // These may only be used if is_initialized() is true. |
Matt Menke | f6edce75 | 2019-03-19 17:21:56 | [diff] [blame] | 200 | const ClientSocketPool::GroupId& group_id() const { return group_id_; } |
Matt Menke | bf3c767d | 2019-04-15 23:28:24 | [diff] [blame] | 201 | int64_t group_generation() const { return group_generation_; } |
[email protected] | a34f61ee | 2014-03-18 20:59:49 | [diff] [blame] | 202 | bool is_reused() const { return reuse_type_ == REUSED_IDLE; } |
[email protected] | f9d285c | 2009-08-17 19:54:29 | [diff] [blame] | 203 | base::TimeDelta idle_time() const { return idle_time_; } |
[email protected] | a34f61ee | 2014-03-18 20:59:49 | [diff] [blame] | 204 | SocketReuseType reuse_type() const { return reuse_type_; } |
[email protected] | 034df0f3 | 2013-01-07 23:17:48 | [diff] [blame] | 205 | const LoadTimingInfo::ConnectTiming& connect_timing() const { |
| 206 | return connect_timing_; |
| 207 | } |
| 208 | void set_connect_timing(const LoadTimingInfo::ConnectTiming& connect_timing) { |
| 209 | connect_timing_ = connect_timing; |
| 210 | } |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 211 | |
| 212 | private: |
[email protected] | 3ae8230 | 2009-06-26 06:01:21 | [diff] [blame] | 213 | // Called on asynchronous completion of an Init() request. |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 214 | void OnIOComplete(int result); |
| 215 | |
[email protected] | 3ae8230 | 2009-06-26 06:01:21 | [diff] [blame] | 216 | // Called on completion (both asynchronous & synchronous) of an Init() |
| 217 | // request. |
| 218 | void HandleInitCompletion(int result); |
| 219 | |
[email protected] | d207a5f | 2009-06-04 05:28:40 | [diff] [blame] | 220 | // Resets the state of the ClientSocketHandle. |cancel| indicates whether or |
[email protected] | e60e47a | 2010-07-14 03:37:18 | [diff] [blame] | 221 | // not to try to cancel the request with the ClientSocketPool. Does not |
Matt Menke | 7eb405e | 2019-04-25 20:48:21 | [diff] [blame] | 222 | // reset the supplemental error state. |cancel_connect_job| indicates whether |
| 223 | // a pending ConnectJob, if there is one in the SocketPool, should be |
| 224 | // cancelled in addition to cancelling the request. It may only be true if |
| 225 | // |cancel| is also true. |
| 226 | void ResetInternal(bool cancel, bool cancel_connect_job); |
[email protected] | e1e0626 | 2008-08-06 23:57:07 | [diff] [blame] | 227 | |
[email protected] | e60e47a | 2010-07-14 03:37:18 | [diff] [blame] | 228 | // Resets the supplemental error state. |
| 229 | void ResetErrorState(); |
| 230 | |
Tsuyoshi Horo | 2ec06e00 | 2022-06-09 01:38:59 | [diff] [blame] | 231 | bool is_initialized_ = false; |
Tsuyoshi Horo | 432981d5 | 2022-06-09 09:50:13 | [diff] [blame] | 232 | raw_ptr<ClientSocketPool> pool_ = nullptr; |
| 233 | raw_ptr<HigherLayeredPool> higher_pool_ = nullptr; |
danakj | 655b66c | 2016-04-16 00:51:38 | [diff] [blame] | 234 | std::unique_ptr<StreamSocket> socket_; |
Matt Menke | f6edce75 | 2019-03-19 17:21:56 | [diff] [blame] | 235 | ClientSocketPool::GroupId group_id_; |
Tsuyoshi Horo | 2ec06e00 | 2022-06-09 01:38:59 | [diff] [blame] | 236 | SocketReuseType reuse_type_ = ClientSocketHandle::UNUSED; |
Bence Béky | a4a5093 | 2018-08-10 13:39:41 | [diff] [blame] | 237 | CompletionOnceCallback callback_; |
[email protected] | f9d285c | 2009-08-17 19:54:29 | [diff] [blame] | 238 | base::TimeDelta idle_time_; |
Matt Menke | bf3c767d | 2019-04-15 23:28:24 | [diff] [blame] | 239 | // See ClientSocketPool::ReleaseSocket() for an explanation. |
Tsuyoshi Horo | 2ec06e00 | 2022-06-09 01:38:59 | [diff] [blame] | 240 | int64_t group_generation_ = -1; |
dalyk | edd30d98 | 2019-12-16 15:31:10 | [diff] [blame] | 241 | ResolveErrorInfo resolve_error_info_; |
Tsuyoshi Horo | 2ec06e00 | 2022-06-09 01:38:59 | [diff] [blame] | 242 | bool is_ssl_error_ = false; |
Matt Menke | 39b7c5a | 2019-04-10 19:47:51 | [diff] [blame] | 243 | scoped_refptr<SSLCertRequestInfo> ssl_cert_request_info_; |
ttuttle | 1f2d7e9 | 2015-04-28 16:17:47 | [diff] [blame] | 244 | std::vector<ConnectionAttempt> connection_attempts_; |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 245 | |
mikecirone | f22f981 | 2016-10-04 03:40:19 | [diff] [blame] | 246 | NetLogSource requesting_source_; |
[email protected] | 06650c5 | 2010-06-03 00:49:17 | [diff] [blame] | 247 | |
[email protected] | 034df0f3 | 2013-01-07 23:17:48 | [diff] [blame] | 248 | // Timing information is set when a connection is successfully established. |
| 249 | LoadTimingInfo::ConnectTiming connect_timing_; |
initial.commit | 586acc5fe | 2008-07-26 22:42:52 | [diff] [blame] | 250 | }; |
| 251 | |
| 252 | } // namespace net |
| 253 | |
[email protected] | f7984fc6 | 2009-06-22 23:26:44 | [diff] [blame] | 254 | #endif // NET_SOCKET_CLIENT_SOCKET_HANDLE_H_ |