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 #include "net/socket/socket_test_util.h" | 5 #include "net/socket/socket_test_util.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1257 ssl_info->token_binding_key_param = data_->token_binding_key_param; | 1257 ssl_info->token_binding_key_param = data_->token_binding_key_param; |
1258 return true; | 1258 return true; |
1259 } | 1259 } |
1260 | 1260 |
1261 void MockSSLClientSocket::GetSSLCertRequestInfo( | 1261 void MockSSLClientSocket::GetSSLCertRequestInfo( |
1262 SSLCertRequestInfo* cert_request_info) { | 1262 SSLCertRequestInfo* cert_request_info) { |
1263 DCHECK(cert_request_info); | 1263 DCHECK(cert_request_info); |
1264 if (data_->cert_request_info) { | 1264 if (data_->cert_request_info) { |
1265 cert_request_info->host_and_port = | 1265 cert_request_info->host_and_port = |
1266 data_->cert_request_info->host_and_port; | 1266 data_->cert_request_info->host_and_port; |
1267 cert_request_info->is_proxy = data_->cert_request_info->is_proxy; | 1267 cert_request_info->client_certs = data_->cert_request_info->client_certs; |
1268 cert_request_info->cert_authorities = | |
1269 data_->cert_request_info->cert_authorities; | |
1270 cert_request_info->cert_key_types = | |
1271 data_->cert_request_info->cert_key_types; | |
1272 } else { | 1268 } else { |
1273 cert_request_info->Reset(); | 1269 cert_request_info->Reset(); |
1274 } | 1270 } |
1275 } | 1271 } |
1276 | 1272 |
1277 ChannelIDService* MockSSLClientSocket::GetChannelIDService() const { | 1273 ChannelIDService* MockSSLClientSocket::GetChannelIDService() const { |
1278 return data_->channel_id_service; | 1274 return data_->channel_id_service; |
1279 } | 1275 } |
1280 | 1276 |
1281 Error MockSSLClientSocket::GetTokenBindingSignature(crypto::ECPrivateKey* key, | 1277 Error MockSSLClientSocket::GetTokenBindingSignature(crypto::ECPrivateKey* key, |
(...skipping 511 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1793 } | 1789 } |
1794 | 1790 |
1795 int64_t CountWriteBytes(const MockWrite writes[], size_t writes_size) { | 1791 int64_t CountWriteBytes(const MockWrite writes[], size_t writes_size) { |
1796 int64_t total = 0; | 1792 int64_t total = 0; |
1797 for (const MockWrite* write = writes; write != writes + writes_size; ++write) | 1793 for (const MockWrite* write = writes; write != writes + writes_size; ++write) |
1798 total += write->data_len; | 1794 total += write->data_len; |
1799 return total; | 1795 return total; |
1800 } | 1796 } |
1801 | 1797 |
1802 } // namespace net | 1798 } // namespace net |
OLD | NEW |