Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(215)

Side by Side Diff: net/socket/ssl_client_socket_openssl.cc

Issue 1814463002: [NOT FOR REVIEW] Instrument net/ with trace events. Base URL: https://chromium.googlesource.com/chromium/src.git@profiler
Patch Set: meh Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « net/socket/socket_posix.cc ('k') | net/socket/ssl_client_socket_pool.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // OpenSSL binding for SSLClientSocket. The class layout and general principle 5 // OpenSSL binding for SSLClientSocket. The class layout and general principle
6 // of operation is derived from SSLClientSocketNSS. 6 // of operation is derived from SSLClientSocketNSS.
7 7
8 #include "net/socket/ssl_client_socket_openssl.h" 8 #include "net/socket/ssl_client_socket_openssl.h"
9 9
10 #include <errno.h> 10 #include <errno.h>
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 #include "net/http/transport_security_state.h" 47 #include "net/http/transport_security_state.h"
48 #include "net/ssl/scoped_openssl_types.h" 48 #include "net/ssl/scoped_openssl_types.h"
49 #include "net/ssl/ssl_cert_request_info.h" 49 #include "net/ssl/ssl_cert_request_info.h"
50 #include "net/ssl/ssl_client_session_cache_openssl.h" 50 #include "net/ssl/ssl_client_session_cache_openssl.h"
51 #include "net/ssl/ssl_connection_status_flags.h" 51 #include "net/ssl/ssl_connection_status_flags.h"
52 #include "net/ssl/ssl_failure_state.h" 52 #include "net/ssl/ssl_failure_state.h"
53 #include "net/ssl/ssl_info.h" 53 #include "net/ssl/ssl_info.h"
54 #include "net/ssl/ssl_private_key.h" 54 #include "net/ssl/ssl_private_key.h"
55 #include "net/ssl/token_binding.h" 55 #include "net/ssl/token_binding.h"
56 56
57 #include "base/trace_event/trace_event.h"
58
57 #if !defined(OS_NACL) 59 #if !defined(OS_NACL)
58 #include "net/ssl/ssl_key_logger.h" 60 #include "net/ssl/ssl_key_logger.h"
59 #endif 61 #endif
60 62
61 #if defined(USE_NSS_CERTS) || defined(OS_IOS) 63 #if defined(USE_NSS_CERTS) || defined(OS_IOS)
62 #include "net/cert_net/nss_ocsp.h" 64 #include "net/cert_net/nss_ocsp.h"
63 #endif 65 #endif
64 66
65 namespace net { 67 namespace net {
66 68
(...skipping 1409 matching lines...) Expand 10 before | Expand all | Expand 10 after
1476 // decrypted data. 1478 // decrypted data.
1477 if (!user_read_buf_.get()) 1479 if (!user_read_buf_.get())
1478 return; 1480 return;
1479 1481
1480 int rv = DoReadLoop(); 1482 int rv = DoReadLoop();
1481 if (rv != ERR_IO_PENDING) 1483 if (rv != ERR_IO_PENDING)
1482 DoReadCallback(rv); 1484 DoReadCallback(rv);
1483 } 1485 }
1484 1486
1485 int SSLClientSocketOpenSSL::DoHandshakeLoop(int last_io_result) { 1487 int SSLClientSocketOpenSSL::DoHandshakeLoop(int last_io_result) {
1488 TRACE_EVENT0("net", "net::SSLClientSocketOpenSSL::DoHandshakeLoop");
1486 int rv = last_io_result; 1489 int rv = last_io_result;
1487 do { 1490 do {
1488 // Default to STATE_NONE for next state. 1491 // Default to STATE_NONE for next state.
1489 // (This is a quirk carried over from the windows 1492 // (This is a quirk carried over from the windows
1490 // implementation. It makes reading the logs a bit harder.) 1493 // implementation. It makes reading the logs a bit harder.)
1491 // State handlers can and often do call GotoState just 1494 // State handlers can and often do call GotoState just
1492 // to stay in the current state. 1495 // to stay in the current state.
1493 State state = next_handshake_state_; 1496 State state = next_handshake_state_;
1494 GotoState(STATE_NONE); 1497 GotoState(STATE_NONE);
1495 switch (state) { 1498 switch (state) {
(...skipping 815 matching lines...) Expand 10 before | Expand all | Expand 10 after
2311 tb_was_negotiated_ = true; 2314 tb_was_negotiated_ = true;
2312 return 1; 2315 return 1;
2313 } 2316 }
2314 } 2317 }
2315 2318
2316 *out_alert_value = SSL_AD_ILLEGAL_PARAMETER; 2319 *out_alert_value = SSL_AD_ILLEGAL_PARAMETER;
2317 return 0; 2320 return 0;
2318 } 2321 }
2319 2322
2320 } // namespace net 2323 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/socket_posix.cc ('k') | net/socket/ssl_client_socket_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698