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 3// found in the LICENSE file. 4 5// NOTE: No header guards are used, since this file is intended to be expanded 6// directly into net_log.h. DO NOT include this file anywhere else. 7 8// In the event of a failure, a many end events will have a |net_error| 9// parameter with the integer error code associated with the failure. Most 10// of these parameters are not individually documented. 11 12// -------------------------------------------------------------------------- 13// General pseudo-events 14// -------------------------------------------------------------------------- 15 16// Something got cancelled (we determine what is cancelled based on the 17// log context around it.) 18EVENT_TYPE(CANCELLED) 19 20// Something failed (we determine what failed based on the log context 21// around it.) 22// The event has the following parameters: 23// 24// { 25// "net_error": <The net error code integer for the failure>, 26// } 27EVENT_TYPE(FAILED) 28 29// Marks the creation/destruction of a request (net::URLRequest or 30// SocketStream). 31EVENT_TYPE(REQUEST_ALIVE) 32 33// ------------------------------------------------------------------------ 34// HostResolverImpl 35// ------------------------------------------------------------------------ 36 37// The start/end of waiting on a host resolve (DNS) request. 38// The BEGIN phase contains the following parameters: 39// 40// { 41// "source_dependency": <Source id of the request being waited on>, 42// } 43EVENT_TYPE(HOST_RESOLVER_IMPL) 44 45// The start/end of a host resolve (DNS) request. Note that these events are 46// logged for all DNS requests, though not all requests result in the creation 47// of a HostResolvedImpl::Request object. 48// 49// The BEGIN phase contains the following parameters: 50// 51// { 52// "host": <Hostname associated with the request>, 53// "address_family": <The address family to restrict results to> 54// "allow_cached_response": <Whether it is ok to return a result from 55// the host cache> 56// "is_speculative": <Whether this request was started by the DNS 57// prefetcher> 58// "source_dependency": <Source id, if any, of what created the request>, 59// } 60// 61// If an error occurred, the END phase will contain these parameters: 62// { 63// "net_error": <The net error code integer for the failure>, 64// } 65EVENT_TYPE(HOST_RESOLVER_IMPL_REQUEST) 66 67// This event is logged when IPv6 support is determined via IPv6 connect probe. 68EVENT_TYPE(HOST_RESOLVER_IMPL_IPV6_SUPPORTED) 69 70// This event is logged when a request is handled by a cache entry. 71EVENT_TYPE(HOST_RESOLVER_IMPL_CACHE_HIT) 72 73// This event is logged when a request is handled by a HOSTS entry. 74EVENT_TYPE(HOST_RESOLVER_IMPL_HOSTS_HIT) 75 76// This event is created when a new HostResolverImpl::Job is about to be created 77// for a request. 78EVENT_TYPE(HOST_RESOLVER_IMPL_CREATE_JOB) 79 80// The creation/completion of a HostResolverImpl::Job which is created for 81// Requests that cannot be resolved synchronously. 82// 83// The BEGIN phase contains the following parameters: 84// 85// { 86// "host": <Hostname associated with the request>, 87// "source_dependency": <Source id, if any, of what created the request>, 88// } 89// 90// On success, the END phase has these parameters: 91// { 92// "address_list": <The host name being resolved>, 93// } 94// If an error occurred, the END phase will contain these parameters: 95// { 96// "net_error": <The net error code integer for the failure>, 97// } 98EVENT_TYPE(HOST_RESOLVER_IMPL_JOB) 99 100// This event is created when a HostResolverImpl::Job is evicted from 101// PriorityDispatch before it can start, because the limit on number of queued 102// Jobs was reached. 103EVENT_TYPE(HOST_RESOLVER_IMPL_JOB_EVICTED) 104 105// This event is created when a HostResolverImpl::Job is started by 106// PriorityDispatch. 107EVENT_TYPE(HOST_RESOLVER_IMPL_JOB_STARTED) 108 109// This event is created when HostResolverImpl::ProcJob is about to start a new 110// attempt to resolve the host. 111// 112// The ATTEMPT_STARTED event has the parameters: 113// 114// { 115// "attempt_number": <the number of the attempt that is resolving the host>, 116// } 117EVENT_TYPE(HOST_RESOLVER_IMPL_ATTEMPT_STARTED) 118 119// This event is created when HostResolverImpl::ProcJob has finished resolving 120// the host. 121// 122// The ATTEMPT_FINISHED event has the parameters: 123// 124// { 125// "attempt_number": <the number of the attempt that has resolved the host>, 126// } 127// If an error occurred, the END phase will contain these additional parameters: 128// { 129// "net_error": <The net error code integer for the failure>, 130// "os_error": <The exact error code integer that getaddrinfo() returned>, 131// } 132EVENT_TYPE(HOST_RESOLVER_IMPL_ATTEMPT_FINISHED) 133 134// This is logged for a request when it's attached to a 135// HostResolverImpl::Job. When this occurs without a preceding 136// HOST_RESOLVER_IMPL_CREATE_JOB entry, it means the request was attached to an 137// existing HostResolverImpl::Job. 138// 139// The event contains the following parameters: 140// 141// { 142// "source_dependency": <Source identifier for the attached Job>, 143// } 144// 145EVENT_TYPE(HOST_RESOLVER_IMPL_JOB_ATTACH) 146 147// This event is logged for the job to which the request is attached. 148// In that case, the event contains the following parameters: 149// 150// { 151// "source_dependency": <Source identifier for the attached Request>, 152// "priority": <New priority of the job>, 153// } 154EVENT_TYPE(HOST_RESOLVER_IMPL_JOB_REQUEST_ATTACH) 155 156// This is logged for a job when a request is cancelled and detached. 157// 158// The event contains the following parameters: 159// 160// { 161// "source_dependency": <Source identifier for the detached Request>, 162// "priority": <New priority of the job>, 163// } 164EVENT_TYPE(HOST_RESOLVER_IMPL_JOB_REQUEST_DETACH) 165 166// The creation/completion of a HostResolverImpl::ProcTask to call getaddrinfo. 167// The BEGIN phase contains the following parameters: 168// 169// { 170// "hostname": <Hostname associated with the request>, 171// } 172// 173// On success, the END phase has these parameters: 174// { 175// "address_list": <The resolved addresses>, 176// } 177// If an error occurred, the END phase will contain these parameters: 178// { 179// "net_error": <The net error code integer for the failure>, 180// "os_error": <The exact error code integer that getaddrinfo() returned>, 181// } 182EVENT_TYPE(HOST_RESOLVER_IMPL_PROC_TASK) 183 184// The creation/completion of a HostResolverImpl::DnsTask to manage a 185// DnsTransaction. The BEGIN phase contains the following parameters: 186// 187// { 188// "source_dependency": <Source id of DnsTransaction>, 189// } 190// 191// On success, the END phase has these parameters: 192// { 193// "address_list": <The resolved addresses>, 194// } 195// If an error occurred, the END phase will contain these parameters: 196// { 197// "net_error": <The net error code integer for the failure>, 198// "dns_error": <The detailed DnsResponse::Result> 199// } 200EVENT_TYPE(HOST_RESOLVER_IMPL_DNS_TASK) 201 202// ------------------------------------------------------------------------ 203// InitProxyResolver 204// ------------------------------------------------------------------------ 205 206// The start/end of auto-detect + custom PAC URL configuration. 207EVENT_TYPE(PROXY_SCRIPT_DECIDER) 208 209// The start/end of when proxy autoconfig was artificially paused following 210// a network change event. (We wait some amount of time after being told of 211// network changes to avoid hitting spurious errors during auto-detect). 212EVENT_TYPE(PROXY_SCRIPT_DECIDER_WAIT) 213 214// The start/end of download of a PAC script. This could be the well-known 215// WPAD URL (if testing auto-detect), or a custom PAC URL. 216// 217// The START event has the parameters: 218// { 219// "source": <String describing where PAC script comes from>, 220// } 221// 222// If the fetch failed, then the END phase has these parameters: 223// { 224// "net_error": <Net error code integer>, 225// } 226EVENT_TYPE(PROXY_SCRIPT_DECIDER_FETCH_PAC_SCRIPT) 227 228// This event means that initialization failed because there was no 229// configured script fetcher. (This indicates a configuration error). 230EVENT_TYPE(PROXY_SCRIPT_DECIDER_HAS_NO_FETCHER) 231 232// This event is emitted after deciding to fall-back to the next source 233// of PAC scripts in the list. 234EVENT_TYPE(PROXY_SCRIPT_DECIDER_FALLING_BACK_TO_NEXT_PAC_SOURCE) 235 236// ------------------------------------------------------------------------ 237// ProxyService 238// ------------------------------------------------------------------------ 239 240// The start/end of a proxy resolve request. 241EVENT_TYPE(PROXY_SERVICE) 242 243// The time while a request is waiting on InitProxyResolver to configure 244// against either WPAD or custom PAC URL. The specifics on this time 245// are found from ProxyService::init_proxy_resolver_log(). 246EVENT_TYPE(PROXY_SERVICE_WAITING_FOR_INIT_PAC) 247 248// This event is emitted to show what the PAC script returned. It can contain 249// extra parameters that are either: 250// { 251// "pac_string": <List of valid proxy servers, in PAC format>, 252// } 253// 254// Or if the the resolver failed: 255// { 256// "net_error": <Net error code that resolver failed with>, 257// } 258EVENT_TYPE(PROXY_SERVICE_RESOLVED_PROXY_LIST) 259 260// This event is emitted whenever the proxy settings used by ProxyService 261// change. 262// 263// It contains these parameters: 264// { 265// "old_config": <Dump of the previous proxy settings>, 266// "new_config": <Dump of the new proxy settings>, 267// } 268// 269// Note that the "old_config" key will be omitted on the first fetch of the 270// proxy settings (since there wasn't a previous value). 271EVENT_TYPE(PROXY_CONFIG_CHANGED) 272 273// Emitted when a list of bad proxies is reported to the proxy service. 274// 275// Parameters: 276// { 277// "bad_proxy_list": <List of bad proxies>, 278// } 279EVENT_TYPE(BAD_PROXY_LIST_REPORTED) 280 281// ------------------------------------------------------------------------ 282// ProxyList 283// ------------------------------------------------------------------------ 284 285// Emitted when the first proxy server in a list is being marked as 286// bad and proxy resolution is going to failover to the next one in 287// the list. The fallback is local to the request. 288// 289// Parameters: 290// { 291// "bad_proxy": <URI representation of the failed proxy server>, 292// } 293EVENT_TYPE(PROXY_LIST_FALLBACK) 294 295// ------------------------------------------------------------------------ 296// ProxyResolverV8Tracing 297// ------------------------------------------------------------------------ 298 299// This event is emitted when a javascript error has been triggered by a 300// PAC script. It contains the following event parameters: 301// { 302// "line_number": <The line number in the PAC script 303// (or -1 if not applicable)>, 304// "message": <The error message>, 305// } 306EVENT_TYPE(PAC_JAVASCRIPT_ERROR) 307 308// This event is emitted when a PAC script called alert(). It contains the 309// following event parameters: 310// { 311// "message": <The string of the alert>, 312// } 313EVENT_TYPE(PAC_JAVASCRIPT_ALERT) 314 315// ------------------------------------------------------------------------ 316// MultiThreadedProxyResolver 317// ------------------------------------------------------------------------ 318 319// Measures the time that a proxy resolve request was stalled waiting for a 320// proxy resolver thread to free-up. 321EVENT_TYPE(WAITING_FOR_PROXY_RESOLVER_THREAD) 322 323// This event is emitted just before a PAC request is bound to a thread. It 324// contains these parameters: 325// 326// { 327// "thread_number": <Identifier for the PAC thread that is going to 328// run this request>, 329// } 330EVENT_TYPE(SUBMITTED_TO_RESOLVER_THREAD) 331 332// ------------------------------------------------------------------------ 333// Socket (Shared by stream and datagram sockets) 334// ------------------------------------------------------------------------ 335 336// Marks the begin/end of a socket (TCP/SOCKS/SSL/UDP/"SpdyProxyClientSocket"). 337// 338// The BEGIN phase contains the following parameters: 339// 340// { 341// "source_dependency": <Source identifier for the controlling entity>, 342// } 343EVENT_TYPE(SOCKET_ALIVE) 344 345// ------------------------------------------------------------------------ 346// StreamSocket 347// ------------------------------------------------------------------------ 348 349// The start/end of a TCP connect(). This corresponds with a call to 350// TCPClientSocket::Connect(). 351// 352// The START event contains these parameters: 353// 354// { 355// "address_list": <List of network address strings>, 356// } 357// 358// And the END event will contain the following parameters: 359// 360// { 361// "net_error": <Net integer error code, on error>, 362// "source_address": <Local source address of the connection, on success>, 363// } 364EVENT_TYPE(TCP_CONNECT) 365 366// Nested within TCP_CONNECT, there may be multiple attempts to connect 367// to the individual addresses. The START event will describe the 368// address the attempt is for: 369// 370// { 371// "address": <String of the network address>, 372// } 373// 374// And the END event will contain the system error code if it failed: 375// 376// { 377// "os_error": <Integer error code the operating system returned>, 378// } 379EVENT_TYPE(TCP_CONNECT_ATTEMPT) 380 381// The start/end of a TCP accept(). This corresponds with a call to 382// TCPServerSocket::Accept(). 383// 384// The END event will contain the following parameters on success: 385// { 386// "address": <Remote address of the accepted connection>, 387// } 388// On failure it contains the following parameters 389// { 390// "net_error": <Net integer error code>, 391// } 392EVENT_TYPE(TCP_ACCEPT) 393 394// This event is logged to the socket stream whenever the socket is 395// acquired/released via a ClientSocketHandle. 396// 397// The BEGIN phase contains the following parameters: 398// 399// { 400// "source_dependency": <Source identifier for the controlling entity>, 401// } 402EVENT_TYPE(SOCKET_IN_USE) 403 404// The start/end of a SOCKS connect(). 405EVENT_TYPE(SOCKS_CONNECT) 406 407// The start/end of a SOCKS5 connect(). 408EVENT_TYPE(SOCKS5_CONNECT) 409 410// This event is emitted when the SOCKS connect fails because the provided 411// was longer than 255 characters. 412EVENT_TYPE(SOCKS_HOSTNAME_TOO_BIG) 413 414// These events are emitted when insufficient data was read while 415// trying to establish a connection to the SOCKS proxy server 416// (during the greeting phase or handshake phase, respectively). 417EVENT_TYPE(SOCKS_UNEXPECTEDLY_CLOSED_DURING_GREETING) 418EVENT_TYPE(SOCKS_UNEXPECTEDLY_CLOSED_DURING_HANDSHAKE) 419 420// This event indicates that a bad version number was received in the 421// proxy server's response. The extra parameters show its value: 422// { 423// "version": <Integer version number in the response>, 424// } 425EVENT_TYPE(SOCKS_UNEXPECTED_VERSION) 426 427// This event indicates that the SOCKS proxy server returned an error while 428// trying to create a connection. The following parameters will be attached 429// to the event: 430// { 431// "error_code": <Integer error code returned by the server>, 432// } 433EVENT_TYPE(SOCKS_SERVER_ERROR) 434 435// This event indicates that the SOCKS proxy server asked for an authentication 436// method that we don't support. The following parameters are attached to the 437// event: 438// { 439// "method": <Integer method code>, 440// } 441EVENT_TYPE(SOCKS_UNEXPECTED_AUTH) 442 443// This event indicates that the SOCKS proxy server's response indicated an 444// address type which we are not prepared to handle. 445// The following parameters are attached to the event: 446// { 447// "address_type": <Integer code for the address type>, 448// } 449EVENT_TYPE(SOCKS_UNKNOWN_ADDRESS_TYPE) 450 451// The start/end of an SSL "connect" (aka client handshake). 452EVENT_TYPE(SSL_CONNECT) 453 454// The start/end of an SSL server handshake (aka "accept"). 455EVENT_TYPE(SSL_SERVER_HANDSHAKE) 456 457// The SSL server requested a client certificate. 458EVENT_TYPE(SSL_CLIENT_CERT_REQUESTED) 459 460// The start/end of getting a domain-bound certificate and private key. 461// 462// The END event will contain the following parameters on failure: 463// 464// { 465// "net_error": <Net integer error code>, 466// } 467EVENT_TYPE(SSL_GET_DOMAIN_BOUND_CERT) 468 469// The SSL server requested a channel id. 470EVENT_TYPE(SSL_CHANNEL_ID_REQUESTED) 471 472// A channel ID was provided to the SSL library to be sent to the SSL server. 473EVENT_TYPE(SSL_CHANNEL_ID_PROVIDED) 474 475// A client certificate (or none) was provided to the SSL library to be sent 476// to the SSL server. 477// The following parameters are attached to the event: 478// { 479// "cert_count": <Number of certificates>, 480// } 481// A cert_count of 0 means no client certificate was provided. 482// A cert_count of -1 means a client certificate was provided but we don't 483// know the size of the certificate chain. 484EVENT_TYPE(SSL_CLIENT_CERT_PROVIDED) 485 486// An SSL error occurred while trying to do the indicated activity. 487// The following parameters are attached to the event: 488// { 489// "net_error": <Integer code for the specific error type>, 490// "ssl_lib_error": <SSL library's integer code for the specific error type> 491// } 492EVENT_TYPE(SSL_HANDSHAKE_ERROR) 493EVENT_TYPE(SSL_READ_ERROR) 494EVENT_TYPE(SSL_WRITE_ERROR) 495 496// An SSL connection needs to be retried with a lower protocol version because 497// the server may be intolerant of the protocol version we offered. 498// The following parameters are attached to the event: 499// { 500// "host_and_port": <String encoding the host and port>, 501// "net_error": <Net integer error code>, 502// "version_before": <SSL version before the fallback>, 503// "version_after": <SSL version after the fallback>, 504// } 505EVENT_TYPE(SSL_VERSION_FALLBACK) 506 507// We found that our prediction of the server's certificates was correct and 508// we merged the verification with the SSLHostInfo. (Note: now obsolete.) 509EVENT_TYPE(SSL_VERIFICATION_MERGED) 510 511// An SSL error occurred while calling an NSS function not directly related to 512// one of the above activities. Can also be used when more information than 513// is provided by just an error code is needed: 514// { 515// "function": <Name of the NSS function, as a string>, 516// "param": <Most relevant parameter, if any>, 517// "ssl_lib_error": <NSS library's integer code for the specific error type> 518// } 519EVENT_TYPE(SSL_NSS_ERROR) 520 521// The specified number of bytes were sent on the socket. Depending on the 522// source of the event, may be logged either once the data is sent, or when it 523// is queued to be sent. 524// The following parameters are attached: 525// { 526// "byte_count": <Number of bytes that were just sent>, 527// "hex_encoded_bytes": <The exact bytes sent, as a hexadecimal string. 528// Only present when byte logging is enabled>, 529// } 530EVENT_TYPE(SOCKET_BYTES_SENT) 531EVENT_TYPE(SSL_SOCKET_BYTES_SENT) 532 533// The specified number of bytes were received on the socket. 534// The following parameters are attached: 535// { 536// "byte_count": <Number of bytes that were just received>, 537// "hex_encoded_bytes": <The exact bytes received, as a hexadecimal string. 538// Only present when byte logging is enabled>, 539// } 540EVENT_TYPE(SOCKET_BYTES_RECEIVED) 541EVENT_TYPE(SSL_SOCKET_BYTES_RECEIVED) 542 543// A socket error occurred while trying to do the indicated activity. 544// The following parameters are attached to the event: 545// { 546// "net_error": <Integer code for the specific error type>, 547// "os_error": <Integer error code the operating system returned> 548// } 549EVENT_TYPE(SOCKET_READ_ERROR) 550EVENT_TYPE(SOCKET_WRITE_ERROR) 551 552// The socket was closed locally (The socket may or may not have been closed 553// by the remote side already) 554EVENT_TYPE(SOCKET_CLOSED) 555 556// Certificates were received from the SSL server (during a handshake or 557// renegotiation). This event is only present when logging at LOG_ALL. 558// The following parameters are attached to the event: 559// { 560// "certificates": <A list of PEM encoded certificates in the order that 561// they were sent by the server>, 562// } 563EVENT_TYPE(SSL_CERTIFICATES_RECEIVED) 564 565// Signed Certificate Timestamps were received from the server. 566// The following parameters are attached to the event: 567// { 568// "embedded_scts": Base64-encoded SignedCertificateTimestampList, 569// "scts_from_ocsp_response": Base64-encoded SignedCertificateTimestampList, 570// "scts_from_tls_extension": Base64-encoded SignedCertificateTimestampList, 571// } 572// 573// The SignedCertificateTimestampList is defined in RFC6962 and is exactly as 574// received from the server. 575EVENT_TYPE(SIGNED_CERTIFICATE_TIMESTAMPS_RECEIVED) 576 577// Signed Certificate Timestamps were checked. 578// The following parameters are attached to the event: 579// { 580// "verified_scts": <A list of SCTs>, 581// "invalid_scts": <A list of SCTs>, 582// "scts_from_unknown_logs": <A list of SCTs>, 583// } 584// 585// Where each SCT is an object: 586// { 587// "origin": <one of: "embedded_in_certificate", "tls_extension", "ocsp">, 588// "version": <numeric version>, 589// "log_id": <base64-encoded log id>, 590// "timestamp": <numeric timestamp in milliseconds since the Unix epoch>, 591// "hash_algorithm": <name of the hash algorithm>, 592// "signature_algorithm": <name of the signature algorithm>, 593// "signature_data": <base64-encoded signature bytes>, 594// } 595EVENT_TYPE(SIGNED_CERTIFICATE_TIMESTAMPS_CHECKED) 596 597// ------------------------------------------------------------------------ 598// DatagramSocket 599// ------------------------------------------------------------------------ 600 601// The start/end of a UDP client connecting. 602// 603// The START event contains these parameters: 604// 605// { 606// "address": <Remote address being connected to>, 607// } 608// 609// And the END event will contain the following parameter: 610// 611// { 612// "net_error": <Net integer error code, on failure>, 613// } 614EVENT_TYPE(UDP_CONNECT) 615 616// The local address of the UDP socket, retrieved via getsockname. 617// The following parameters are attached: 618// { 619// "address": <Local address bound to the socket>, 620// } 621EVENT_TYPE(UDP_LOCAL_ADDRESS) 622 623// The specified number of bytes were transferred on the socket. 624// The following parameters are attached: 625// { 626// "address": <Remote address of data transfer. Not present when not 627// specified for UDP_BYTES_SENT events>, 628// "byte_count": <Number of bytes that were just received>, 629// "hex_encoded_bytes": <The exact bytes received, as a hexadecimal string. 630// Only present when byte logging is enabled>, 631// } 632EVENT_TYPE(UDP_BYTES_RECEIVED) 633EVENT_TYPE(UDP_BYTES_SENT) 634 635// Logged when an error occurs while reading or writing to/from a UDP socket. 636// The following parameters are attached: 637// { 638// "net_error": <Net error code>, 639// } 640EVENT_TYPE(UDP_RECEIVE_ERROR) 641EVENT_TYPE(UDP_SEND_ERROR) 642 643// ------------------------------------------------------------------------ 644// ClientSocketPoolBase::ConnectJob 645// ------------------------------------------------------------------------ 646 647// The start/end of a ConnectJob. 648// 649// The BEGIN phase has these parameters: 650// 651// { 652// "group_name": <The group name for the socket request.>, 653// } 654EVENT_TYPE(SOCKET_POOL_CONNECT_JOB) 655 656// The start/end of the ConnectJob::Connect(). 657EVENT_TYPE(SOCKET_POOL_CONNECT_JOB_CONNECT) 658 659// This event is logged whenever the ConnectJob gets a new socket 660// association. The event parameters point to that socket: 661// 662// { 663// "source_dependency": <The source identifier for the new socket.>, 664// } 665EVENT_TYPE(CONNECT_JOB_SET_SOCKET) 666 667// Whether the connect job timed out. 668EVENT_TYPE(SOCKET_POOL_CONNECT_JOB_TIMED_OUT) 669 670// ------------------------------------------------------------------------ 671// ClientSocketPoolBaseHelper 672// ------------------------------------------------------------------------ 673 674// The start/end of a client socket pool request for a socket. 675EVENT_TYPE(SOCKET_POOL) 676 677// The request stalled because there are too many sockets in the pool. 678EVENT_TYPE(SOCKET_POOL_STALLED_MAX_SOCKETS) 679 680// The request stalled because there are too many sockets in the group. 681EVENT_TYPE(SOCKET_POOL_STALLED_MAX_SOCKETS_PER_GROUP) 682 683// Indicates that we reused an existing socket. Attached to the event are 684// the parameters: 685// { 686// "idle_ms": <The number of milliseconds the socket was sitting idle for>, 687// } 688EVENT_TYPE(SOCKET_POOL_REUSED_AN_EXISTING_SOCKET) 689 690// This event simply describes the host:port that were requested from the 691// socket pool. Its parameters are: 692// { 693// "host_and_port": <String encoding the host and port>, 694// } 695EVENT_TYPE(TCP_CLIENT_SOCKET_POOL_REQUESTED_SOCKET) 696 697// This event simply describes the host:port that were requested from the 698// socket pool. Its parameters are: 699// { 700// "host_and_port": <String encoding the host and port>, 701// } 702EVENT_TYPE(TCP_CLIENT_SOCKET_POOL_REQUESTED_SOCKETS) 703 704 705// A backup connect job is created due to slow connect. 706EVENT_TYPE(BACKUP_CONNECT_JOB_CREATED) 707 708// This event is sent when a connect job is eventually bound to a request 709// (because of late binding and socket backup jobs, we don't assign the job to 710// a request until it has completed). 711// 712// The event parameters are: 713// { 714// "source_dependency": <Source identifer for the connect job we are 715// bound to>, 716// } 717EVENT_TYPE(SOCKET_POOL_BOUND_TO_CONNECT_JOB) 718 719// Identifies the NetLog::Source() for the Socket assigned to the pending 720// request. The event parameters are: 721// { 722// "source_dependency": <Source identifier for the socket we acquired>, 723// } 724EVENT_TYPE(SOCKET_POOL_BOUND_TO_SOCKET) 725 726// The start/end of a client socket pool request for multiple sockets. 727// The event parameters are: 728// { 729// "num_sockets": <Number of sockets we're trying to ensure are connected>, 730// } 731EVENT_TYPE(SOCKET_POOL_CONNECTING_N_SOCKETS) 732 733// ------------------------------------------------------------------------ 734// URLRequest 735// ------------------------------------------------------------------------ 736 737// Measures the time it took a net::URLRequestJob to start. For the most part 738// this corresponds with the time between net::URLRequest::Start() and 739// net::URLRequest::ResponseStarted(), however it is also repeated for every 740// redirect, and every intercepted job that handles the request. 741// 742// For the BEGIN phase, the following parameters are attached: 743// { 744// "url": <String of URL being loaded>, 745// "method": <The method ("POST" or "GET" or "HEAD" etc..)>, 746// "load_flags": <Numeric value of the combined load flags>, 747// "priority": <Numeric priority of the request>, 748// "upload_id" <String of upload body identifier, if present>, 749// } 750// 751// For the END phase, if there was an error, the following parameters are 752// attached: 753// { 754// "net_error": <Net error code of the failure>, 755// } 756EVENT_TYPE(URL_REQUEST_START_JOB) 757 758// This event is sent once a net::URLRequest receives a redirect. The parameters 759// attached to the event are: 760// { 761// "location": <The URL that was redirected to>, 762// } 763EVENT_TYPE(URL_REQUEST_REDIRECTED) 764 765// Measures the time between when a net::URLRequest calls a delegate that can 766// block it, and when the delegate allows the request to resume. 767EVENT_TYPE(URL_REQUEST_DELEGATE) 768 769// Logged when a delegate informs the URL_REQUEST of what's currently blocking 770// the request. The parameters attached to the begin event are: 771// { 772// "delegate_info": <Information about what's blocking the request>, 773// } 774EVENT_TYPE(DELEGATE_INFO) 775 776// The specified number of bytes were read from the net::URLRequest. 777// The filtered event is used when the bytes were passed through a filter before 778// being read. This event is only present when byte logging is enabled. 779// The following parameters are attached: 780// { 781// "byte_count": <Number of bytes that were just sent>, 782// "hex_encoded_bytes": <The exact bytes sent, as a hexadecimal string>, 783// } 784EVENT_TYPE(URL_REQUEST_JOB_BYTES_READ) 785EVENT_TYPE(URL_REQUEST_JOB_FILTERED_BYTES_READ) 786 787// This event is sent when the priority of a net::URLRequest is 788// changed after it has started. The following parameters are attached: 789// { 790// "priority": <Numerical value of the priority (higher is more important)>, 791// } 792EVENT_TYPE(URL_REQUEST_SET_PRIORITY) 793 794EVENT_TYPE(URL_REQUEST_REDIRECT_JOB) 795// This event is logged when a URLRequestRedirectJob is started for a request. 796// The following parameters are attached: 797// { 798// "reason": <Reason for the redirect, as a string>, 799// } 800 801EVENT_TYPE(URL_REQUEST_FAKE_RESPONSE_HEADERS_CREATED) 802// This event is logged when a URLRequestRedirectJob creates the fake response 803// headers for a request, prior to returning them. 804// The following parameters are attached: 805// { 806// "headers": <The list of header:value pairs>, 807// } 808 809// ------------------------------------------------------------------------ 810// HttpCache 811// ------------------------------------------------------------------------ 812 813// Measures the time while getting a reference to the back end. 814EVENT_TYPE(HTTP_CACHE_GET_BACKEND) 815 816// Measures the time while opening a disk cache entry. 817EVENT_TYPE(HTTP_CACHE_OPEN_ENTRY) 818 819// Measures the time while creating a disk cache entry. 820EVENT_TYPE(HTTP_CACHE_CREATE_ENTRY) 821 822// Measures the time it takes to add a HttpCache::Transaction to an http cache 823// entry's list of active Transactions. 824EVENT_TYPE(HTTP_CACHE_ADD_TO_ENTRY) 825 826// Measures the time while deleting a disk cache entry. 827EVENT_TYPE(HTTP_CACHE_DOOM_ENTRY) 828 829// Measures the time while reading/writing a disk cache entry's response headers 830// or metadata. 831EVENT_TYPE(HTTP_CACHE_READ_INFO) 832EVENT_TYPE(HTTP_CACHE_WRITE_INFO) 833 834// Measures the time while reading/writing a disk cache entry's body. 835EVENT_TYPE(HTTP_CACHE_READ_DATA) 836EVENT_TYPE(HTTP_CACHE_WRITE_DATA) 837 838// ------------------------------------------------------------------------ 839// Disk Cache / Memory Cache 840// ------------------------------------------------------------------------ 841 842// The creation/destruction of a disk_cache::EntryImpl object. The "creation" 843// is considered to be the point at which an Entry is first considered to be 844// good and associated with a key. Note that disk and memory cache entries 845// share event types. 846// 847// For the BEGIN phase, the following parameters are attached: 848// { 849// "created": <true if the Entry was created, rather than being opened>, 850// "key": <The Entry's key>, 851// } 852EVENT_TYPE(DISK_CACHE_ENTRY_IMPL) 853EVENT_TYPE(DISK_CACHE_MEM_ENTRY_IMPL) 854 855// Logs the time required to read/write data from/to a cache entry. 856// 857// For the BEGIN phase, the following parameters are attached: 858// { 859// "index": <Index being read/written>, 860// "offset": <Offset being read/written>, 861// "buf_len": <Length of buffer being read to/written from>, 862// "truncate": <If present for a write, the truncate flag is set to true. 863// Not present in reads or writes where it is false>, 864// } 865// 866// For the END phase, the following parameters are attached: 867// { 868// "bytes_copied": <Number of bytes copied. Not present on error>, 869// "net_error": <Network error code. Only present on error>, 870// } 871EVENT_TYPE(ENTRY_READ_DATA) 872EVENT_TYPE(ENTRY_WRITE_DATA) 873 874// Logged when sparse read/write operation starts/stops for an Entry. 875// 876// For the BEGIN phase, the following parameters are attached: 877// { 878// "offset": <Offset at which to start reading>, 879// "buff_len": <Bytes to read/write>, 880// } 881EVENT_TYPE(SPARSE_READ) 882EVENT_TYPE(SPARSE_WRITE) 883 884// Logged when a parent Entry starts/stops reading/writing a child Entry's data. 885// 886// For the BEGIN phase, the following parameters are attached: 887// { 888// "source_dependency": <Source id of the child entry>, 889// "child_len": <Bytes to read/write from/to child>, 890// } 891EVENT_TYPE(SPARSE_READ_CHILD_DATA) 892EVENT_TYPE(SPARSE_WRITE_CHILD_DATA) 893 894// Logged when sparse GetAvailableRange operation starts/stops for an Entry. 895// 896// For the BEGIN phase, the following parameters are attached: 897// { 898// "buff_len": <Bytes to read/write>, 899// "offset": <Offset at which to start reading>, 900// } 901// 902// For the END phase, the following parameters are attached. No parameters are 903// attached when cancelled: 904// { 905// "length": <Length of returned range. Only present on success>, 906// "start": <Position where returned range starts. Only present on success>, 907// "net_error": <Resulting error code. Only present on failure. This may be 908// "OK" when there's no error, but no available bytes in the 909// range>, 910// } 911EVENT_TYPE(SPARSE_GET_RANGE) 912 913// Indicates the children of a sparse EntryImpl are about to be deleted. 914// Not logged for MemEntryImpls. 915EVENT_TYPE(SPARSE_DELETE_CHILDREN) 916 917// Logged when an EntryImpl is closed. Not logged for MemEntryImpls. 918EVENT_TYPE(ENTRY_CLOSE) 919 920// Logged when an entry is doomed. 921EVENT_TYPE(ENTRY_DOOM) 922 923// ------------------------------------------------------------------------ 924// HttpStreamFactoryImpl 925// ------------------------------------------------------------------------ 926 927// Measures the time taken to fulfill the HttpStreamRequest. 928EVENT_TYPE(HTTP_STREAM_REQUEST) 929 930// Measures the time taken to execute the HttpStreamFactoryImpl::Job 931EVENT_TYPE(HTTP_STREAM_JOB) 932 933// Identifies the NetLog::Source() for the Job that fulfilled the Request. 934// The event parameters are: 935// { 936// "source_dependency": <Source identifier for Job we acquired>, 937// } 938EVENT_TYPE(HTTP_STREAM_REQUEST_BOUND_TO_JOB) 939 940// Identifies the NetLog::Source() for the Request that the Job was attached to. 941// The event parameters are: 942// { 943// "source_dependency": <Source identifier for the Request to which we were 944// attached>, 945// } 946EVENT_TYPE(HTTP_STREAM_JOB_BOUND_TO_REQUEST) 947 948// Logs the protocol negotiated with the server. The event parameters are: 949// { 950// "status": <The NPN status ("negotiated", "unsupported", "no-overlap")>, 951// "proto": <The NPN protocol negotiated>, 952// "server_protos": <The list of server advertised protocols>, 953// } 954EVENT_TYPE(HTTP_STREAM_REQUEST_PROTO) 955 956// ------------------------------------------------------------------------ 957// HttpNetworkTransaction 958// ------------------------------------------------------------------------ 959 960// Measures the time taken to send the tunnel request to the server. 961EVENT_TYPE(HTTP_TRANSACTION_TUNNEL_SEND_REQUEST) 962 963// This event is sent for a tunnel request. 964// The following parameters are attached: 965// { 966// "line": <The HTTP request line, CRLF terminated>, 967// "headers": <The list of header:value pairs>, 968// } 969EVENT_TYPE(HTTP_TRANSACTION_SEND_TUNNEL_HEADERS) 970 971// Measures the time to read the tunnel response headers from the server. 972EVENT_TYPE(HTTP_TRANSACTION_TUNNEL_READ_HEADERS) 973 974// This event is sent on receipt of the HTTP response headers to a tunnel 975// request. 976// The following parameters are attached: 977// { 978// "headers": <The list of header:value pairs>, 979// } 980EVENT_TYPE(HTTP_TRANSACTION_READ_TUNNEL_RESPONSE_HEADERS) 981 982// Measures the time taken to send the request to the server. 983EVENT_TYPE(HTTP_TRANSACTION_SEND_REQUEST) 984 985// This event is sent for a HTTP request. 986// The following parameters are attached: 987// { 988// "line": <The HTTP request line, CRLF terminated>, 989// "headers": <The list of header:value pairs>, 990// } 991EVENT_TYPE(HTTP_TRANSACTION_SEND_REQUEST_HEADERS) 992 993// Logged when a request body is sent. 994// The following parameters are attached: 995// { 996// "did_merge": <True if the body was merged with the headers for writing>, 997// "is_chunked": <True if chunked>, 998// "length": <The length of the body. May not be accurate when body is not 999// in memory> 1000// } 1001EVENT_TYPE(HTTP_TRANSACTION_SEND_REQUEST_BODY) 1002 1003// This event is sent for a HTTP request over a SPDY stream. 1004// The following parameters are attached: 1005// { 1006// "headers": <The list of header:value pairs>, 1007// } 1008EVENT_TYPE(HTTP_TRANSACTION_SPDY_SEND_REQUEST_HEADERS) 1009 1010// This event is sent for a HTTP request over a SPDY stream. 1011// The following parameters are attached: 1012// { 1013// "headers": <The list of header:value pairs>, 1014// "quic_priority": <Integer representing the priority of this request>, 1015// "quic_stream_id": <Id of the QUIC stream sending this request>, 1016// } 1017EVENT_TYPE(HTTP_TRANSACTION_QUIC_SEND_REQUEST_HEADERS) 1018 1019// Measures the time to read HTTP response headers from the server. 1020EVENT_TYPE(HTTP_TRANSACTION_READ_HEADERS) 1021 1022// This event is sent on receipt of the HTTP response headers. 1023// The following parameters are attached: 1024// { 1025// "headers": <The list of header:value pairs>, 1026// } 1027EVENT_TYPE(HTTP_TRANSACTION_READ_RESPONSE_HEADERS) 1028 1029// Measures the time to read the entity body from the server. 1030EVENT_TYPE(HTTP_TRANSACTION_READ_BODY) 1031 1032// Measures the time taken to read the response out of the socket before 1033// restarting for authentication, on keep alive connections. 1034EVENT_TYPE(HTTP_TRANSACTION_DRAIN_BODY_FOR_AUTH_RESTART) 1035 1036// This event is sent when we try to restart a transaction after an error. 1037// The following parameters are attached: 1038// { 1039// "net_error": <The net error code integer for the failure, if applicable>, 1040// "http_status_code": <HTTP status code indicating an error, if 1041// applicable>, 1042// } 1043EVENT_TYPE(HTTP_TRANSACTION_RESTART_AFTER_ERROR) 1044 1045// ------------------------------------------------------------------------ 1046// SpdySession 1047// ------------------------------------------------------------------------ 1048 1049// The start/end of a SpdySession. 1050// { 1051// "host": <The host-port string>, 1052// "proxy": <The Proxy PAC string>, 1053// } 1054EVENT_TYPE(SPDY_SESSION) 1055 1056// The SpdySession has been initilized with a socket. 1057// { 1058// "source_dependency": <Source identifier for the underlying socket>, 1059// } 1060EVENT_TYPE(SPDY_SESSION_INITIALIZED) 1061 1062// This event is sent for a SPDY SYN_STREAM. 1063// The following parameters are attached: 1064// { 1065// "flags": <The control frame flags>, 1066// "headers": <The list of header:value pairs>, 1067// "id": <The stream id>, 1068// } 1069EVENT_TYPE(SPDY_SESSION_SYN_STREAM) 1070 1071// This event is sent for a SPDY SYN_STREAM pushed by the server, where a 1072// net::URLRequest is already waiting for the stream. 1073// The following parameters are attached: 1074// { 1075// "flags": <The control frame flags>, 1076// "headers": <The list of header:value pairs>, 1077// "id": <The stream id>, 1078// "associated_stream": <The stream id>, 1079// } 1080EVENT_TYPE(SPDY_SESSION_PUSHED_SYN_STREAM) 1081 1082// This event is sent for a sending SPDY HEADERS frame. 1083// The following parameters are attached: 1084// { 1085// "flags": <The control frame flags>, 1086// "headers": <The list of header:value pairs>, 1087// "id": <The stream id>, 1088// } 1089EVENT_TYPE(SPDY_SESSION_SEND_HEADERS) 1090 1091// This event is sent for a receiving SPDY HEADERS frame. 1092// The following parameters are attached: 1093// { 1094// "flags": <The control frame flags>, 1095// "headers": <The list of header:value pairs>, 1096// "id": <The stream id>, 1097// } 1098EVENT_TYPE(SPDY_SESSION_RECV_HEADERS) 1099 1100// This event is sent for a SPDY SYN_REPLY. 1101// The following parameters are attached: 1102// { 1103// "flags": <The control frame flags>, 1104// "headers": <The list of header:value pairs>, 1105// "id": <The stream id>, 1106// } 1107EVENT_TYPE(SPDY_SESSION_SYN_REPLY) 1108 1109// On sending a SPDY SETTINGS frame. 1110// The following parameters are attached: 1111// { 1112// "settings": <The list of setting id, flags and value>, 1113// } 1114EVENT_TYPE(SPDY_SESSION_SEND_SETTINGS) 1115 1116// Receipt of a SPDY SETTINGS frame is received. 1117// The following parameters are attached: 1118// { 1119// "host": <The host-port string>, 1120// "clear_persisted": <Boolean indicating whether to clear all persisted 1121// settings data for the given host>, 1122// } 1123EVENT_TYPE(SPDY_SESSION_RECV_SETTINGS) 1124 1125// Receipt of a SPDY SETTING frame. 1126// The following parameters are attached: 1127// { 1128// "id": <The setting id>, 1129// "flags": <The setting flags>, 1130// "value": <The setting value>, 1131// } 1132EVENT_TYPE(SPDY_SESSION_RECV_SETTING) 1133 1134// The receipt of a RST_STREAM 1135// The following parameters are attached: 1136// { 1137// "stream_id": <The stream ID for the window update>, 1138// "status": <The reason for the RST_STREAM>, 1139// } 1140EVENT_TYPE(SPDY_SESSION_RST_STREAM) 1141 1142// Sending of a RST_STREAM 1143// The following parameters are attached: 1144// { 1145// "stream_id": <The stream ID for the window update>, 1146// "status": <The reason for the RST_STREAM>, 1147// "description": <The textual description for the RST_STREAM>, 1148// } 1149EVENT_TYPE(SPDY_SESSION_SEND_RST_STREAM) 1150 1151// Sending of a SPDY PING frame. 1152// The following parameters are attached: 1153// { 1154// "unique_id": <The unique id of the PING message>, 1155// "type": <The PING type ("sent", "received")>, 1156// } 1157EVENT_TYPE(SPDY_SESSION_PING) 1158 1159// Receipt of a SPDY GOAWAY frame. 1160// The following parameters are attached: 1161// { 1162// "last_accepted_stream_id": <Last stream id accepted by the server, duh>, 1163// "active_streams": <Number of active streams>, 1164// "unclaimed_streams": <Number of unclaimed push streams>, 1165// "status": <The reason for the GOAWAY>, 1166// } 1167EVENT_TYPE(SPDY_SESSION_GOAWAY) 1168 1169// Receipt of a SPDY WINDOW_UPDATE frame (which controls the send window). 1170// { 1171// "stream_id": <The stream ID for the window update>, 1172// "delta" : <The delta window size>, 1173// } 1174EVENT_TYPE(SPDY_SESSION_RECEIVED_WINDOW_UPDATE_FRAME) 1175 1176// Sending of a SPDY WINDOW_UPDATE frame (which controls the receive window). 1177// { 1178// "stream_id": <The stream ID for the window update>, 1179// "delta" : <The delta window size>, 1180// } 1181EVENT_TYPE(SPDY_SESSION_SENT_WINDOW_UPDATE_FRAME) 1182 1183// This event indicates that the send window has been updated for a session. 1184// { 1185// "delta": <The window size delta>, 1186// "new_window": <The new window size>, 1187// } 1188EVENT_TYPE(SPDY_SESSION_UPDATE_SEND_WINDOW) 1189 1190// This event indicates that the recv window has been updated for a session. 1191// { 1192// "delta": <The window size delta>, 1193// "new_window": <The new window size>, 1194// } 1195EVENT_TYPE(SPDY_SESSION_UPDATE_RECV_WINDOW) 1196 1197// Sending of a SPDY CREDENTIAL frame (which sends a certificate or 1198// certificate chain to the server). 1199// { 1200// "slot" : <The slot that this certificate should be stored in>, 1201// "origin" : <The origin this certificate should be used for>, 1202// } 1203EVENT_TYPE(SPDY_SESSION_SEND_CREDENTIAL) 1204 1205// Sending a data frame 1206// { 1207// "stream_id": <The stream ID for the window update>, 1208// "length" : <The size of data sent>, 1209// "flags" : <Send data flags>, 1210// } 1211EVENT_TYPE(SPDY_SESSION_SEND_DATA) 1212 1213// Receiving a data frame 1214// { 1215// "stream_id": <The stream ID for the window update>, 1216// "length" : <The size of data received>, 1217// "flags" : <Receive data flags>, 1218// } 1219EVENT_TYPE(SPDY_SESSION_RECV_DATA) 1220 1221// This event is sent for a receiving SPDY PUSH_PROMISE frame. 1222// The following parameters are attached: 1223// { 1224// "headers": <The list of header:value pairs>, 1225// "id": <The stream id>, 1226// "promised_stream_id": <The stream id>, 1227// } 1228EVENT_TYPE(SPDY_SESSION_RECV_PUSH_PROMISE) 1229 1230// A stream is stalled by the session send window being closed. 1231EVENT_TYPE(SPDY_SESSION_STREAM_STALLED_BY_SESSION_SEND_WINDOW) 1232 1233// A stream is stalled by its send window being closed. 1234EVENT_TYPE(SPDY_SESSION_STREAM_STALLED_BY_STREAM_SEND_WINDOW) 1235 1236// Session is closing 1237// { 1238// "net_error" : <The error status of the closure>, 1239// "description": <The textual description for the closure>, 1240// } 1241EVENT_TYPE(SPDY_SESSION_CLOSE) 1242 1243// Event when the creation of a stream is stalled because we're at 1244// the maximum number of concurrent streams. 1245EVENT_TYPE(SPDY_SESSION_STALLED_MAX_STREAMS) 1246 1247// Received a value for initial window size in SETTINGS frame with 1248// flow control turned off. 1249EVENT_TYPE(SPDY_SESSION_INITIAL_WINDOW_SIZE_NO_FLOW_CONTROL) 1250 1251// Received an out-of-range value for initial window size in SETTINGS 1252// frame. 1253// { 1254// "initial_window_size" : <The initial window size>, 1255// } 1256EVENT_TYPE(SPDY_SESSION_INITIAL_WINDOW_SIZE_OUT_OF_RANGE) 1257 1258// Updating streams send window size by the delta window size. 1259// { 1260// "delta_window_size" : <The delta window size>, 1261// } 1262EVENT_TYPE(SPDY_SESSION_UPDATE_STREAMS_SEND_WINDOW_SIZE) 1263 1264// ------------------------------------------------------------------------ 1265// SpdySessionPool 1266// ------------------------------------------------------------------------ 1267 1268// This event indicates the pool is reusing an existing session 1269// { 1270// "source_dependency": <The session id>, 1271// } 1272EVENT_TYPE(SPDY_SESSION_POOL_FOUND_EXISTING_SESSION) 1273 1274// This event indicates the pool is reusing an existing session from an 1275// IP pooling match. 1276// { 1277// "source_dependency": <The session id>, 1278// } 1279EVENT_TYPE(SPDY_SESSION_POOL_FOUND_EXISTING_SESSION_FROM_IP_POOL) 1280 1281// This event indicates the pool created a new session 1282// { 1283// "source_dependency": <The session id>, 1284// } 1285EVENT_TYPE(SPDY_SESSION_POOL_CREATED_NEW_SESSION) 1286 1287// This event indicates that a SSL socket has been upgraded to a SPDY session. 1288// { 1289// "source_dependency": <The session id>, 1290// } 1291EVENT_TYPE(SPDY_SESSION_POOL_IMPORTED_SESSION_FROM_SOCKET) 1292 1293// This event indicates that the session has been removed. 1294// { 1295// "source_dependency": <The session id>, 1296// } 1297EVENT_TYPE(SPDY_SESSION_POOL_REMOVE_SESSION) 1298 1299// ------------------------------------------------------------------------ 1300// SpdyStream 1301// ------------------------------------------------------------------------ 1302 1303// The begin and end of a SPDY STREAM. 1304EVENT_TYPE(SPDY_STREAM) 1305 1306// A stream is attached to a pushed stream. 1307EVENT_TYPE(SPDY_STREAM_ADOPTED_PUSH_STREAM) 1308 1309// A stream is unstalled by flow control. 1310EVENT_TYPE(SPDY_STREAM_FLOW_CONTROL_UNSTALLED) 1311 1312// This event indicates that the send window has been updated for a stream. 1313// { 1314// "id": <The stream id>, 1315// "delta": <The window size delta>, 1316// "new_window": <The new window size>, 1317// } 1318EVENT_TYPE(SPDY_STREAM_UPDATE_SEND_WINDOW) 1319 1320// This event indicates that the recv window has been updated for a stream. 1321// { 1322// "id": <The stream id>, 1323// "delta": <The window size delta>, 1324// "new_window": <The new window size>, 1325// } 1326EVENT_TYPE(SPDY_STREAM_UPDATE_RECV_WINDOW) 1327 1328// This event indicates a stream error 1329// { 1330// "id": <The stream id>, 1331// "status": <The error status>, 1332// "description": <The textual description for the error>, 1333// } 1334EVENT_TYPE(SPDY_STREAM_ERROR) 1335 1336// ------------------------------------------------------------------------ 1337// SpdyProxyClientSocket 1338// ------------------------------------------------------------------------ 1339 1340EVENT_TYPE(SPDY_PROXY_CLIENT_SESSION) 1341// Identifies the SPDY session a source is using. 1342// { 1343// "source_dependency": <Source identifier for the underlying session>, 1344// } 1345 1346// ------------------------------------------------------------------------ 1347// QuicSession 1348// ------------------------------------------------------------------------ 1349 1350// The start/end of a QuicSession. 1351// { 1352// "host": <The host-port string>, 1353// } 1354EVENT_TYPE(QUIC_SESSION) 1355 1356// Session is closing because of an error. 1357// { 1358// "net_error": <Net error code for the closure>, 1359// } 1360EVENT_TYPE(QUIC_SESSION_CLOSE_ON_ERROR) 1361 1362// Session verified a certificate from the server. 1363// { 1364// "subjects": <list of DNS names that the certificate is valid for>, 1365// } 1366EVENT_TYPE(QUIC_SESSION_CERTIFICATE_VERIFIED) 1367 1368// Session received a QUIC packet. 1369// { 1370// "peer_address": <The ip:port of the peer>, 1371// "self_address": <The local ip:port which received the packet>, 1372// } 1373EVENT_TYPE(QUIC_SESSION_PACKET_RECEIVED) 1374 1375// Session sent a QUIC packet. 1376// { 1377// "encryption_level": <The EncryptionLevel of the packet>, 1378// "transmission_type": <The TransmissionType of the packet>, 1379// "packet_sequence_number": <The packet's full 64-bit sequence number, 1380// as a base-10 string.>, 1381// "size": <The size of the packet in bytes> 1382// } 1383EVENT_TYPE(QUIC_SESSION_PACKET_SENT) 1384 1385// Session retransmitted a QUIC packet. 1386// { 1387// "old_packet_sequence_number": <The old packet's full 64-bit sequence 1388// number, as a base-10 string.>, 1389// "new_packet_sequence_number": <The new packet's full 64-bit sequence 1390// number, as a base-10 string.>, 1391// } 1392EVENT_TYPE(QUIC_SESSION_PACKET_RETRANSMITTED) 1393 1394// Session received a QUIC packet header for a valid packet. 1395// { 1396// "connection_id": <The 64-bit CONNECTION_ID for this connection, as a 1397// base-10 string>, 1398// "public_flags": <The public flags set for this packet>, 1399// "packet_sequence_number": <The packet's full 64-bit sequence number, 1400// as a base-10 string.>, 1401// "private_flags": <The private flags set for this packet>, 1402// "fec_group": <The FEC group of this packet>, 1403// } 1404EVENT_TYPE(QUIC_SESSION_PACKET_HEADER_RECEIVED) 1405 1406// Session received a STREAM frame. 1407// { 1408// "stream_id": <The id of the stream which this data is for>, 1409// "fin": <True if this is the final data set by the peer on this stream>, 1410// "offset": <Offset in the byte stream where this data starts>, 1411// "length": <Length of the data in this frame>, 1412// } 1413EVENT_TYPE(QUIC_SESSION_STREAM_FRAME_RECEIVED) 1414 1415// Session sent a STREAM frame. 1416// { 1417// "stream_id": <The id of the stream which this data is for>, 1418// "fin": <True if this is the final data set by the peer on this stream>, 1419// "offset": <Offset in the byte stream where this data starts>, 1420// "length": <Length of the data in this frame>, 1421// } 1422EVENT_TYPE(QUIC_SESSION_STREAM_FRAME_SENT) 1423 1424// Session received an ACK frame. 1425// { 1426// "sent_info": <Details of packet sent by the peer> 1427// { 1428// "least_unacked": <Lowest sequence number of a packet sent by the peer 1429// for which it has not received an ACK>, 1430// } 1431// "received_info": <Details of packet received by the peer> 1432// { 1433// "largest_observed": <The largest sequence number of a packet received 1434// by (or inferred by) the peer>, 1435// "missing": <List of sequence numbers of packets lower than 1436// largest_observed which have not been received by the 1437// peer>, 1438// } 1439// } 1440EVENT_TYPE(QUIC_SESSION_ACK_FRAME_RECEIVED) 1441 1442// Session sent an ACK frame. 1443// { 1444// "sent_info": <Details of packet sent by the peer> 1445// { 1446// "least_unacked": <Lowest sequence number of a packet sent by the peer 1447// for which it has not received an ACK>, 1448// } 1449// "received_info": <Details of packet received by the peer> 1450// { 1451// "largest_observed": <The largest sequence number of a packet received 1452// by (or inferred by) the peer>, 1453// "missing": <List of sequence numbers of packets lower than 1454// largest_observed which have not been received by the 1455// peer>, 1456// } 1457// } 1458EVENT_TYPE(QUIC_SESSION_ACK_FRAME_SENT) 1459 1460// Session received a WINDOW_UPDATE frame. 1461// { 1462// "stream_id": <The id of the stream which this data is for>, 1463// "byte_offset": <Byte offset in the stream>, 1464// } 1465EVENT_TYPE(QUIC_SESSION_WINDOW_UPDATE_FRAME_RECEIVED) 1466 1467// Session sent a WINDOW_UPDATE frame. 1468// { 1469// "stream_id": <The id of the stream which this data is for>, 1470// "byte_offset": <Byte offset in the stream>, 1471// } 1472EVENT_TYPE(QUIC_SESSION_WINDOW_UPDATE_FRAME_SENT) 1473 1474// Session received a BLOCKED frame. 1475// { 1476// "stream_id": <The id of the stream which this data is for>, 1477// } 1478EVENT_TYPE(QUIC_SESSION_BLOCKED_FRAME_RECEIVED) 1479 1480// Session sent a BLOCKED frame. 1481// { 1482// "stream_id": <The id of the stream which this data is for>, 1483// } 1484EVENT_TYPE(QUIC_SESSION_BLOCKED_FRAME_SENT) 1485 1486// Session received a GOAWAY frame. 1487// { 1488// "quic_error": <QuicErrorCode in the frame>, 1489// "last_good_stream_id": <Last correctly received stream id by the server>, 1490// "reason_phrase": <Prose justifying go-away request>, 1491// } 1492EVENT_TYPE(QUIC_SESSION_GOAWAY_FRAME_RECEIVED) 1493 1494// Session sent a GOAWAY frame. 1495// { 1496// "quic_error": <QuicErrorCode in the frame>, 1497// "last_good_stream_id": <Last correctly received stream id by the server>, 1498// "reason_phrase": <Prose justifying go-away request>, 1499// } 1500EVENT_TYPE(QUIC_SESSION_GOAWAY_FRAME_SENT) 1501 1502// Session received a PING frame. 1503EVENT_TYPE(QUIC_SESSION_PING_FRAME_RECEIVED) 1504 1505// Session sent a PING frame. 1506EVENT_TYPE(QUIC_SESSION_PING_FRAME_SENT) 1507 1508// Session received a STOP_WAITING frame. 1509// { 1510// "sent_info": <Details of packet sent by the peer> 1511// { 1512// "least_unacked": <Lowest sequence number of a packet sent by the peer 1513// for which it has not received an ACK>, 1514// } 1515// } 1516EVENT_TYPE(QUIC_SESSION_STOP_WAITING_FRAME_RECEIVED) 1517 1518// Session sent an STOP_WAITING frame. 1519// { 1520// "sent_info": <Details of packet sent by the peer> 1521// { 1522// "least_unacked": <Lowest sequence number of a packet sent by the peer 1523// for which it has not received an ACK>, 1524// } 1525// } 1526EVENT_TYPE(QUIC_SESSION_STOP_WAITING_FRAME_SENT) 1527 1528// Session recevied a RST_STREAM frame. 1529// { 1530// "offset": <Offset in the byte stream which triggered the reset>, 1531// "quic_rst_stream_error": <QuicRstStreamErrorCode in the frame>, 1532// "details": <Human readable description>, 1533// } 1534EVENT_TYPE(QUIC_SESSION_RST_STREAM_FRAME_RECEIVED) 1535 1536// Session sent a RST_STREAM frame. 1537// { 1538// "offset": <Offset in the byte stream which triggered the reset>, 1539// "quic_rst_stream_error": <QuicRstStreamErrorCode in the frame>, 1540// "details": <Human readable description>, 1541// } 1542EVENT_TYPE(QUIC_SESSION_RST_STREAM_FRAME_SENT) 1543 1544// Session received a CONGESTION_FEEDBACK frame. 1545// { 1546// "type": <The specific type of feedback being provided>, 1547// Other per-feedback type details: 1548// 1549// for InterArrival: 1550// "accumulated_number_of_lost_packets": <Total number of lost packets 1551// over the life of this session>, 1552// "received_packets": <List of strings of the form: 1553// <sequence_number>@<receive_time_in_ms>>, 1554// 1555// for FixRate: 1556// "bitrate_in_bytes_per_second": <The configured bytes per second>, 1557// 1558// for TCP: 1559// "accumulated_number_of_lost_packets": <Total number of lost packets 1560// over the life of this session>, 1561// "receive_window": <Number of bytes in the receive window>, 1562// } 1563EVENT_TYPE(QUIC_SESSION_CONGESTION_FEEDBACK_FRAME_RECEIVED) 1564 1565// Session received a CONGESTION_FEEDBACK frame. 1566// { 1567// "type": <The specific type of feedback being provided>, 1568// Other per-feedback type details: 1569// 1570// for InterArrival: 1571// "accumulated_number_of_lost_packets": <Total number of lost packets 1572// over the life of this session>, 1573// "received_packets": <List of strings of the form: 1574// <sequence_number>@<receive_time_in_ms>>, 1575// 1576// for FixRate: 1577// "bitrate_in_bytes_per_second": <The configured bytes per second>, 1578// 1579// for TCP: 1580// "accumulated_number_of_lost_packets": <Total number of lost packets 1581// over the life of this session>, 1582// "receive_window": <Number of bytes in the receive window>, 1583// } 1584EVENT_TYPE(QUIC_SESSION_CONGESTION_FEEDBACK_FRAME_SENT) 1585 1586// Session received a CONNECTION_CLOSE frame. 1587// { 1588// "quic_error": <QuicErrorCode in the frame>, 1589// "details": <Human readable description>, 1590// } 1591EVENT_TYPE(QUIC_SESSION_CONNECTION_CLOSE_FRAME_RECEIVED) 1592 1593// Session received a CONNECTION_CLOSE frame. 1594// { 1595// "quic_error": <QuicErrorCode in the frame>, 1596// "details": <Human readable description>, 1597// } 1598EVENT_TYPE(QUIC_SESSION_CONNECTION_CLOSE_FRAME_SENT) 1599 1600// Session received a public reset packet. 1601// { 1602// } 1603EVENT_TYPE(QUIC_SESSION_PUBLIC_RESET_PACKET_RECEIVED) 1604 1605// Session received a version negotiation packet. 1606// { 1607// "versions": <List of QUIC versions supported by the server>, 1608// } 1609EVENT_TYPE(QUIC_SESSION_VERSION_NEGOTIATION_PACKET_RECEIVED) 1610 1611// Session sucessfully negotiated QUIC version number. 1612// { 1613// "version": <String of QUIC version negotiated with the server>, 1614// } 1615EVENT_TYPE(QUIC_SESSION_VERSION_NEGOTIATED) 1616 1617// Session revived a QUIC packet packet via FEC. 1618// { 1619// "connection_id": <The 64-bit CONNECTION_ID for this connection, as a 1620// base-10 string>, 1621// "public_flags": <The public flags set for this packet>, 1622// "packet_sequence_number": <The packet's full 64-bit sequence number, 1623// as a base-10 string.>, 1624// "private_flags": <The private flags set for this packet>, 1625// "fec_group": <The FEC group of this packet>, 1626// } 1627EVENT_TYPE(QUIC_SESSION_PACKET_HEADER_REVIVED) 1628 1629// Session received a crypto handshake message. 1630// { 1631// "quic_crypto_handshake_message": <The human readable dump of the message 1632// contents> 1633// } 1634EVENT_TYPE(QUIC_SESSION_CRYPTO_HANDSHAKE_MESSAGE_RECEIVED) 1635 1636// Session sent a crypto handshake message. 1637// { 1638// "quic_crypto_handshake_message": <The human readable dump of the message 1639// contents> 1640// } 1641EVENT_TYPE(QUIC_SESSION_CRYPTO_HANDSHAKE_MESSAGE_SENT) 1642 1643// Session was closed, either remotely or by the peer. 1644// { 1645// "quic_error": <QuicErrorCode which caused the connection to be closed>, 1646// "from_peer": <True if the peer closed the connection> 1647// } 1648EVENT_TYPE(QUIC_SESSION_CLOSED) 1649 1650// ------------------------------------------------------------------------ 1651// QuicHttpStream 1652// ------------------------------------------------------------------------ 1653 1654// The stream is sending the request headers. 1655// { 1656// "headers": <The list of header:value pairs> 1657// } 1658EVENT_TYPE(QUIC_HTTP_STREAM_SEND_REQUEST_HEADERS) 1659 1660// The stream has read the response headers. 1661// { 1662// "headers": <The list of header:value pairs> 1663// } 1664EVENT_TYPE(QUIC_HTTP_STREAM_READ_RESPONSE_HEADERS) 1665 1666// ------------------------------------------------------------------------ 1667// HttpStreamParser 1668// ------------------------------------------------------------------------ 1669 1670// Measures the time to read HTTP response headers from the server. 1671EVENT_TYPE(HTTP_STREAM_PARSER_READ_HEADERS) 1672 1673// ------------------------------------------------------------------------ 1674// SocketStream 1675// ------------------------------------------------------------------------ 1676 1677// Measures the time between SocketStream::Connect() and 1678// SocketStream::DidEstablishConnection() 1679// 1680// For the BEGIN phase, the following parameters are attached: 1681// { 1682// "url": <String of URL being loaded>, 1683// } 1684// 1685// For the END phase, if there was an error, the following parameters are 1686// attached: 1687// { 1688// "net_error": <Net error code of the failure>, 1689// } 1690EVENT_TYPE(SOCKET_STREAM_CONNECT) 1691 1692// A message sent on the SocketStream. 1693EVENT_TYPE(SOCKET_STREAM_SENT) 1694 1695// A message received on the SocketStream. 1696EVENT_TYPE(SOCKET_STREAM_RECEIVED) 1697 1698// ------------------------------------------------------------------------ 1699// WebSocketJob 1700// ------------------------------------------------------------------------ 1701 1702// This event is sent for a WebSocket handshake request. 1703// The following parameters are attached: 1704// { 1705// "headers": <handshake request message>, 1706// } 1707EVENT_TYPE(WEB_SOCKET_SEND_REQUEST_HEADERS) 1708 1709// This event is sent on receipt of the WebSocket handshake response headers. 1710// The following parameters are attached: 1711// { 1712// "headers": <handshake response message>, 1713// } 1714EVENT_TYPE(WEB_SOCKET_READ_RESPONSE_HEADERS) 1715 1716// ------------------------------------------------------------------------ 1717// SOCKS5ClientSocket 1718// ------------------------------------------------------------------------ 1719 1720// The time spent sending the "greeting" to the SOCKS server. 1721EVENT_TYPE(SOCKS5_GREET_WRITE) 1722 1723// The time spent waiting for the "greeting" response from the SOCKS server. 1724EVENT_TYPE(SOCKS5_GREET_READ) 1725 1726// The time spent sending the CONNECT request to the SOCKS server. 1727EVENT_TYPE(SOCKS5_HANDSHAKE_WRITE) 1728 1729// The time spent waiting for the response to the CONNECT request. 1730EVENT_TYPE(SOCKS5_HANDSHAKE_READ) 1731 1732// ------------------------------------------------------------------------ 1733// HTTP Authentication 1734// ------------------------------------------------------------------------ 1735 1736// The time spent authenticating to the proxy. 1737EVENT_TYPE(AUTH_PROXY) 1738 1739// The time spent authentication to the server. 1740EVENT_TYPE(AUTH_SERVER) 1741 1742// ------------------------------------------------------------------------ 1743// HTML5 Application Cache 1744// ------------------------------------------------------------------------ 1745 1746// This event is emitted whenever a request is satistifed directly from 1747// the appache. 1748EVENT_TYPE(APPCACHE_DELIVERING_CACHED_RESPONSE) 1749 1750// This event is emitted whenever the appcache uses a fallback response. 1751EVENT_TYPE(APPCACHE_DELIVERING_FALLBACK_RESPONSE) 1752 1753// This event is emitted whenever the appcache generates an error response. 1754EVENT_TYPE(APPCACHE_DELIVERING_ERROR_RESPONSE) 1755 1756// This event is emitted whenever the appcache executes script to compute 1757// a response. 1758EVENT_TYPE(APPCACHE_DELIVERING_EXECUTABLE_RESPONSE) 1759 1760// ------------------------------------------------------------------------ 1761// Global events 1762// ------------------------------------------------------------------------ 1763// These are events which are not grouped by source id, as they have no 1764// context. 1765 1766// This event is emitted whenever NetworkChangeNotifier determines that an 1767// active network adapter's IP address has changed. 1768EVENT_TYPE(NETWORK_IP_ADDRESSES_CHANGED) 1769 1770// This event is emitted whenever NetworkChangeNotifier determines that an 1771// active network adapter's connectivity status has changed. 1772// { 1773// "new_connection_type": <Type of the new connection> 1774// } 1775EVENT_TYPE(NETWORK_CONNECTIVITY_CHANGED) 1776 1777// This event is emitted whenever NetworkChangeNotifier determines that a change 1778// occurs to the host computer's hardware or software that affects the route 1779// network packets take to any network server. 1780// { 1781// "new_connection_type": <Type of the new connection> 1782// } 1783EVENT_TYPE(NETWORK_CHANGED) 1784 1785// This event is emitted whenever HostResolverImpl receives a new DnsConfig 1786// from the DnsConfigService. 1787// { 1788// "nameservers": <List of name server IPs>, 1789// "search": <List of domain suffixes>, 1790// "num_hosts": <Number of entries in the HOSTS file>, 1791// <other>: <See DnsConfig> 1792// } 1793EVENT_TYPE(DNS_CONFIG_CHANGED) 1794 1795// ------------------------------------------------------------------------ 1796// Exponential back-off throttling events 1797// ------------------------------------------------------------------------ 1798 1799// Emitted when back-off is disabled for a given host, or the first time 1800// a localhost URL is used (back-off is always disabled for localhost). 1801// { 1802// "host": <The hostname back-off was disabled for> 1803// } 1804EVENT_TYPE(THROTTLING_DISABLED_FOR_HOST) 1805 1806// Emitted when a request is denied due to exponential back-off throttling. 1807// { 1808// "url": <URL that was being requested>, 1809// "num_failures": <Failure count for the URL>, 1810// "release_after_ms": <Number of milliseconds until URL will be unblocked> 1811// } 1812EVENT_TYPE(THROTTLING_REJECTED_REQUEST) 1813 1814// ------------------------------------------------------------------------ 1815// DnsTransaction 1816// ------------------------------------------------------------------------ 1817 1818// The start/end of a DnsTransaction. 1819// 1820// The BEGIN phase contains the following parameters: 1821// 1822// { 1823// "hostname": <The hostname it is trying to resolve>, 1824// "query_type": <Type of the query>, 1825// } 1826// 1827// The END phase contains the following parameters: 1828// 1829// { 1830// "net_error": <The net error code for the failure, if any>, 1831// } 1832EVENT_TYPE(DNS_TRANSACTION) 1833 1834// The start/end of a DnsTransaction query for a fully-qualified domain name. 1835// 1836// The BEGIN phase contains the following parameters: 1837// 1838// { 1839// "qname": <The fully-qualified domain name it is trying to resolve>, 1840// } 1841// 1842// The END phase contains the following parameters: 1843// 1844// { 1845// "net_error": <The net error code for the failure, if any>, 1846// } 1847EVENT_TYPE(DNS_TRANSACTION_QUERY) 1848 1849// This event is created when DnsTransaction creates a new UDP socket and 1850// tries to resolve the fully-qualified name. 1851// 1852// It has a single parameter: 1853// 1854// { 1855// "source_dependency": <Source id of the UDP socket created for the 1856// attempt>, 1857// } 1858EVENT_TYPE(DNS_TRANSACTION_ATTEMPT) 1859 1860// This event is created when DnsTransaction creates a new TCP socket and 1861// tries to resolve the fully-qualified name. 1862// 1863// It has a single parameter: 1864// 1865// { 1866// "source_dependency": <Source id of the TCP socket created for the 1867// attempt>, 1868// } 1869EVENT_TYPE(DNS_TRANSACTION_TCP_ATTEMPT) 1870 1871// This event is created when DnsTransaction receives a matching response. 1872// 1873// It has the following parameters: 1874// 1875// { 1876// "rcode": <rcode in the received response>, 1877// "answer_count": <answer_count in the received response>, 1878// "source_dependency": <Source id of the UDP socket that received the 1879// response>, 1880// } 1881EVENT_TYPE(DNS_TRANSACTION_RESPONSE) 1882 1883// ------------------------------------------------------------------------ 1884// ChromeExtension 1885// ------------------------------------------------------------------------ 1886 1887// TODO(eroman): This is a layering violation. Fix this in the context 1888// of http://crbug.com/90674. 1889 1890// This event is created when a Chrome extension aborts a request. 1891// 1892// { 1893// "extension_id": <Extension ID that caused the abortion> 1894// } 1895EVENT_TYPE(CHROME_EXTENSION_ABORTED_REQUEST) 1896 1897// This event is created when a Chrome extension redirects a request. 1898// 1899// { 1900// "extension_id": <Extension ID that caused the redirection> 1901// } 1902EVENT_TYPE(CHROME_EXTENSION_REDIRECTED_REQUEST) 1903 1904// This event is created when a Chrome extension modifieds the headers of a 1905// request. 1906// 1907// { 1908// "extension_id": <Extension ID that caused the modification>, 1909// "modified_headers": [ "<header>: <value>", ... ], 1910// "deleted_headers": [ "<header>", ... ] 1911// } 1912EVENT_TYPE(CHROME_EXTENSION_MODIFIED_HEADERS) 1913 1914// This event is created when a Chrome extension tried to modify a request 1915// but was ignored due to a conflict. 1916// 1917// { 1918// "extension_id": <Extension ID that was ignored> 1919// } 1920EVENT_TYPE(CHROME_EXTENSION_IGNORED_DUE_TO_CONFLICT) 1921 1922// This event is created when a Chrome extension provides authentication 1923// credentials. 1924// 1925// { 1926// "extension_id": <Extension ID that provides credentials> 1927// } 1928EVENT_TYPE(CHROME_EXTENSION_PROVIDE_AUTH_CREDENTIALS) 1929 1930// ------------------------------------------------------------------------ 1931// HostBlacklistManager 1932// ------------------------------------------------------------------------ 1933 1934// TODO(joaodasilva): Layering violation, see comment above. 1935// http://crbug.com/90674. 1936 1937// This event is created when a request is blocked by a policy. 1938EVENT_TYPE(CHROME_POLICY_ABORTED_REQUEST) 1939 1940// ------------------------------------------------------------------------ 1941// CertVerifier 1942// ------------------------------------------------------------------------ 1943 1944// This event is created when we start a CertVerifier request. 1945EVENT_TYPE(CERT_VERIFIER_REQUEST) 1946 1947// This event is created when we start a CertVerifier job. 1948// The BEGIN phase event parameters are: 1949// { 1950// "certificates": <A list of PEM encoded certificates, the first one 1951// being the certificate to verify and the remaining 1952// being intermediate certificates to assist path 1953// building. Only present when byte logging is enabled.> 1954// } 1955// 1956// The END phase event parameters are: 1957// { 1958// "cert_status": <Bitmask of CERT_STATUS_* 1959// from net/base/cert_status_flags.h> 1960// "common_name_fallback_used": <True if a fallback to the common name 1961// was used when matching the host 1962// name, rather than using the 1963// subjectAltName.> 1964// "has_md2": <True if a certificate in the certificate chain is signed with 1965// a MD2 signature.> 1966// "has_md4": <True if a certificate in the certificate chain is signed with 1967// a MD4 signature.> 1968// "has_md5": <True if a certificate in the certificate chain is signed with 1969// a MD5 signature.> 1970// "is_issued_by_additional_trust_anchor": <True if the root CA used for 1971// this verification came from the 1972// list of additional trust 1973// anchors.> 1974// "is_issued_by_known_root": <True if we recognise the root CA as a 1975// standard root. If it isn't then it's 1976// probably the case that this certificate 1977// was generated by a MITM proxy whose root 1978// has been installed locally. This is 1979// meaningless if the certificate was not 1980// trusted.> 1981// "public_key_hashes": <If the certificate was successfully verified then 1982// this contains the hashes, in several hash 1983// algorithms, of the SubjectPublicKeyInfos of the 1984// chain.> 1985// "verified_cert": <The certificate chain that was constructed 1986// during verification. Note that though the verified 1987// certificate will match the originally supplied 1988// certificate, the intermediate certificates stored 1989// within may be substantially different. In the event 1990// of a verification failure, this will contain the 1991// chain as supplied by the server. This may be NULL 1992// if running within the sandbox.> 1993// } 1994EVENT_TYPE(CERT_VERIFIER_JOB) 1995 1996// This event is created when a CertVerifier request attaches to a job. 1997// 1998// The event parameters are: 1999// { 2000// "source_dependency": <Source identifer for the job we are bound to>, 2001// } 2002EVENT_TYPE(CERT_VERIFIER_REQUEST_BOUND_TO_JOB) 2003 2004// ------------------------------------------------------------------------ 2005// Download start events. 2006// ------------------------------------------------------------------------ 2007 2008// This event is created when a download is started, and lets the URL request 2009// event source know what download source it is using. 2010// { 2011// "source_dependency": <Source id of the download>, 2012// } 2013EVENT_TYPE(DOWNLOAD_STARTED) 2014 2015// This event is created when a download is started, and lets the download 2016// event source know what URL request it's associated with. 2017// { 2018// "source_dependency": <Source id of the request being waited on>, 2019// } 2020EVENT_TYPE(DOWNLOAD_URL_REQUEST) 2021 2022// ------------------------------------------------------------------------ 2023// DownloadItem events. 2024// ------------------------------------------------------------------------ 2025 2026// This event lives for as long as a download item is active. 2027// The BEGIN event occurs right after constrction, and has the following 2028// parameters: 2029// { 2030// "type": <New/history/save page>, 2031// "id": <Download ID>, 2032// "original_url": <URL that initiated the download>, 2033// "final_url": <URL of the actual download file>, 2034// "file_name": <initial file name, based on DownloadItem's members: 2035// For History downloads it's the |full_path_| 2036// For other downloads, uses the first non-empty variable of: 2037// |state_info.force_filename| 2038// |suggested_filename_| 2039// the filename specified in the final URL>, 2040// "danger_type": <NOT_DANGEROUS, DANGEROUS_FILE, DANGEROUS_URL, 2041// DANGEROUS_CONTENT, MAYBE_DANGEROUS_CONTENT, 2042// UNCOMMON_CONTENT, USER_VALIDATED, DANGEROUS_HOST, 2043// POTENTIALLY_UNWANTED>, 2044// "start_offset": <Where to start writing (defaults to 0)>, 2045// "has_user_gesture": <Whether or not we think the user initiated 2046// the download> 2047// } 2048// The END event will occur when the download is interrupted, canceled or 2049// completed. 2050// DownloadItems that are loaded from history and are never active simply ADD 2051// one of these events. 2052EVENT_TYPE(DOWNLOAD_ITEM_ACTIVE) 2053 2054// This event is created when a download item's danger type 2055// has been modified. 2056// { 2057// "danger_type": <The new danger type. See above for possible values.>, 2058// } 2059EVENT_TYPE(DOWNLOAD_ITEM_SAFETY_STATE_UPDATED) 2060 2061// This event is created when a download item is updated. 2062// { 2063// "bytes_so_far": <Number of bytes received>, 2064// "hash_state": <Current hash state, as a hex-encoded binary string>, 2065// } 2066EVENT_TYPE(DOWNLOAD_ITEM_UPDATED) 2067 2068// This event is created when a download item is renamed. 2069// { 2070// "old_filename": <Old file name>, 2071// "new_filename": <New file name>, 2072// } 2073EVENT_TYPE(DOWNLOAD_ITEM_RENAMED) 2074 2075// This event is created when a download item is interrupted. 2076// { 2077// "interrupt_reason": <The reason for the interruption>, 2078// "bytes_so_far": <Number of bytes received>, 2079// "hash_state": <Current hash state, as a hex-encoded binary string>, 2080// } 2081EVENT_TYPE(DOWNLOAD_ITEM_INTERRUPTED) 2082 2083// This event is created when a download item is resumed. 2084// { 2085// "user_initiated": <True if user initiated resume>, 2086// "reason": <The reason for the interruption>, 2087// "bytes_so_far": <Number of bytes received>, 2088// "hash_state": <Current hash state, as a hex-encoded binary string>, 2089// } 2090EVENT_TYPE(DOWNLOAD_ITEM_RESUMED) 2091 2092// This event is created when a download item is completing. 2093// { 2094// "bytes_so_far": <Number of bytes received>, 2095// "final_hash": <Final hash, as a hex-encoded binary string>, 2096// } 2097EVENT_TYPE(DOWNLOAD_ITEM_COMPLETING) 2098 2099// This event is created when a download item is finished. 2100// { 2101// "auto_opened": <Whether or not the download was auto-opened> 2102// } 2103EVENT_TYPE(DOWNLOAD_ITEM_FINISHED) 2104 2105// This event is created when a download item is canceled. 2106// { 2107// "bytes_so_far": <Number of bytes received>, 2108// "hash_state": <Current hash state, as a hex-encoded binary string>, 2109// } 2110EVENT_TYPE(DOWNLOAD_ITEM_CANCELED) 2111 2112// ------------------------------------------------------------------------ 2113// DownloadFile events. 2114// ------------------------------------------------------------------------ 2115 2116// This event is created when a download file is opened, and lasts until 2117// the file is closed. 2118// The BEGIN event has the following parameters: 2119// { 2120// "file_name": <The name of the file>, 2121// "start_offset": <The position at which to start writing>, 2122// } 2123EVENT_TYPE(DOWNLOAD_FILE_OPENED) 2124 2125// This event is created when the stream between download source 2126// and download file is drained. 2127// { 2128// "stream_size": <Total size of all bytes drained from the stream> 2129// "num_buffers": <How many separate buffers those bytes were in> 2130// } 2131EVENT_TYPE(DOWNLOAD_STREAM_DRAINED) 2132 2133// This event is created when a download file is renamed. 2134// { 2135// "old_filename": <Old filename>, 2136// "new_filename": <New filename>, 2137// } 2138EVENT_TYPE(DOWNLOAD_FILE_RENAMED) 2139 2140// This event is created when a download file is closed. This event is allowed 2141// to occur even if the file is not open. 2142EVENT_TYPE(DOWNLOAD_FILE_CLOSED) 2143 2144// This event is created when a download file is detached. 2145EVENT_TYPE(DOWNLOAD_FILE_DETACHED) 2146 2147// This event is created when a download file is deleted. 2148EVENT_TYPE(DOWNLOAD_FILE_DELETED) 2149 2150// This event is created when a download file operation has an error. 2151// { 2152// "operation": <open, write, close, etc>, 2153// "net_error": <net::Error code>, 2154// "os_error": <OS depedent error code> 2155// "interrupt_reason": <Download interrupt reason> 2156// } 2157EVENT_TYPE(DOWNLOAD_FILE_ERROR) 2158 2159// This event is created when a download file is annotating with source 2160// information (for Mark Of The Web and anti-virus integration). 2161EVENT_TYPE(DOWNLOAD_FILE_ANNOTATED) 2162 2163// ------------------------------------------------------------------------ 2164// FileStream events. 2165// ------------------------------------------------------------------------ 2166 2167// This event lasts the lifetime of a file stream. 2168EVENT_TYPE(FILE_STREAM_ALIVE) 2169 2170// This event is created when a file stream is associated with a NetLog source. 2171// It indicates what file stream event source is used. 2172// { 2173// "source_dependency": <Source id of the file stream>, 2174// } 2175EVENT_TYPE(FILE_STREAM_SOURCE) 2176 2177// This event is created when a file stream is associated with a NetLog source. 2178// It indicates what event source owns the file stream source. 2179// { 2180// "source_dependency": <Source id of the owner of the file stream>, 2181// } 2182EVENT_TYPE(FILE_STREAM_BOUND_TO_OWNER) 2183 2184// Mark the opening/closing of a file stream. 2185// The BEGIN event has the following parameters: 2186// { 2187// "file_name". 2188// } 2189EVENT_TYPE(FILE_STREAM_OPEN) 2190 2191// This event is created when a file stream operation has an error. 2192// { 2193// "operation": <open, write, close, etc>, 2194// "os_error": <OS-dependent error code>, 2195// "net_error": <net::Error code>, 2196// } 2197EVENT_TYPE(FILE_STREAM_ERROR) 2198 2199// ----------------------------------------------------------------------------- 2200// FTP events. 2201// ----------------------------------------------------------------------------- 2202 2203// This event is created when an FTP command is sent. It contains following 2204// parameters: 2205// { 2206// "command": <String - the command sent to remote server> 2207// } 2208EVENT_TYPE(FTP_COMMAND_SENT) 2209 2210// This event is created when FTP control connection is made. It contains 2211// following parameters: 2212// { 2213// "source_dependency": <id of log for control connection socket> 2214// } 2215EVENT_TYPE(FTP_CONTROL_CONNECTION) 2216 2217// This event is created when FTP data connection is made. It contains 2218// following parameters: 2219// { 2220// "source_dependency": <id of log for data connection socket> 2221// } 2222EVENT_TYPE(FTP_DATA_CONNECTION) 2223 2224// This event is created when FTP control connection response is processed. 2225// It contains following parameters: 2226// { 2227// "lines": <list of strings - each representing a line of the response> 2228// "status_code": <numeric status code of the response> 2229// } 2230EVENT_TYPE(FTP_CONTROL_RESPONSE) 2231 2232// ----------------------------------------------------------------------------- 2233// Simple Cache events. 2234// ----------------------------------------------------------------------------- 2235 2236// This event lasts the lifetime of a Simple Cache entry. 2237// It contains the following parameter: 2238// { 2239// "entry_hash": <hash of the entry, formatted as a hex string> 2240// } 2241EVENT_TYPE(SIMPLE_CACHE_ENTRY) 2242 2243// This event is created when the entry's key is set. 2244// It contains the following parameter: 2245// { 2246// "key": <key of the entry> 2247// } 2248EVENT_TYPE(SIMPLE_CACHE_ENTRY_SET_KEY) 2249 2250// This event is created when OpenEntry is called. It has no parameters. 2251EVENT_TYPE(SIMPLE_CACHE_ENTRY_OPEN_CALL) 2252 2253// This event is created when the Simple Cache actually begins opening the 2254// cache entry. It has no parameters. 2255EVENT_TYPE(SIMPLE_CACHE_ENTRY_OPEN_BEGIN) 2256 2257// This event is created when the Simple Cache finishes the OpenEntry call. 2258// It contains the following parameter: 2259// { 2260// "net_error": <net error code returned from the call> 2261// } 2262EVENT_TYPE(SIMPLE_CACHE_ENTRY_OPEN_END) 2263 2264// This event is created when CreateEntry is called. It has no parameters. 2265EVENT_TYPE(SIMPLE_CACHE_ENTRY_CREATE_CALL) 2266 2267// This event is created when the Simple Cache optimistically returns a result 2268// from a CreateEntry call before it performs the create operation. 2269// It contains the following parameter: 2270// { 2271// "net_error": <net error code returned from the call> 2272// } 2273EVENT_TYPE(SIMPLE_CACHE_ENTRY_CREATE_OPTIMISTIC) 2274 2275// This event is created when the Simple Cache actually begins creating the 2276// cache entry. It has no parameters. 2277EVENT_TYPE(SIMPLE_CACHE_ENTRY_CREATE_BEGIN) 2278 2279// This event is created when the Simple Cache finishes the CreateEntry call. 2280// It contains the following parameter: 2281// { 2282// "net_error": <net error code returned from the call> 2283// } 2284EVENT_TYPE(SIMPLE_CACHE_ENTRY_CREATE_END) 2285 2286// This event is created when ReadEntry is called. 2287// It contains the following parameters: 2288// { 2289// "index": <Index being read/written>, 2290// "offset": <Offset being read/written>, 2291// "buf_len": <Length of buffer being read to/written from>, 2292// "truncate": <If present for a write, the truncate flag is set to true. 2293// Not present in reads or writes where it is false>, 2294// } 2295EVENT_TYPE(SIMPLE_CACHE_ENTRY_READ_CALL) 2296 2297// This event is created when the Simple Cache actually begins reading data 2298// from the cache entry. 2299// It contains the following parameters: 2300// { 2301// "index": <Index being read/written>, 2302// "offset": <Offset being read/written>, 2303// "buf_len": <Length of buffer being read to/written from>, 2304// "truncate": <If present for a write, the truncate flag is set to true. 2305// Not present in reads or writes where it is false>, 2306// } 2307EVENT_TYPE(SIMPLE_CACHE_ENTRY_READ_BEGIN) 2308 2309// This event is created when the Simple Cache finishes a ReadEntry call. 2310// It contains the following parameters: 2311// { 2312// "bytes_copied": <Number of bytes copied. Not present on error>, 2313// "net_error": <Network error code. Only present on error>, 2314// } 2315EVENT_TYPE(SIMPLE_CACHE_ENTRY_READ_END) 2316 2317// This event is created when the Simple Cache begins to verify the checksum of 2318// cached data it has just read. It occurs before READ_END, and contains no 2319// parameters. 2320EVENT_TYPE(SIMPLE_CACHE_ENTRY_CHECKSUM_BEGIN) 2321 2322// This event is created when the Simple Cache finishes verifying the checksum 2323// of cached data. It occurs after CHECKSUM_BEGIN but before READ_END, and 2324// contains one parameter: 2325// { 2326// "net_error": <net error code returned from the internal checksum call> 2327// } 2328EVENT_TYPE(SIMPLE_CACHE_ENTRY_CHECKSUM_END) 2329 2330// This event is created when WriteEntry is called. 2331// It contains the following parameters: 2332// { 2333// "index": <Index being read/written>, 2334// "offset": <Offset being read/written>, 2335// "buf_len": <Length of buffer being read to/written from>, 2336// "truncate": <If present for a write, the truncate flag is set to true. 2337// Not present in reads or writes where it is false>, 2338// } 2339EVENT_TYPE(SIMPLE_CACHE_ENTRY_WRITE_CALL) 2340 2341// This event is created when the Simple Cache optimistically returns a result 2342// from a WriteData call before it performs the write operation. 2343// It contains the following parameters: 2344// { 2345// "bytes_copied": <Number of bytes copied. Not present on error>, 2346// "net_error": <Network error code. Only present on error>, 2347// } 2348EVENT_TYPE(SIMPLE_CACHE_ENTRY_WRITE_OPTIMISTIC) 2349 2350// This event is created when the Simple Cache actually begins writing data to 2351// the cache entry. 2352// It contains the following parameters: 2353// { 2354// "index": <Index being read/written>, 2355// "offset": <Offset being read/written>, 2356// "buf_len": <Length of buffer being read to/written from>, 2357// "truncate": <If present for a write, the truncate flag is set to true. 2358// Not present in reads or writes where it is false>, 2359// } 2360EVENT_TYPE(SIMPLE_CACHE_ENTRY_WRITE_BEGIN) 2361 2362// This event is created when the Simple Cache finishes a WriteEntry call. 2363// It contains the following parameters: 2364// { 2365// "bytes_copied": <Number of bytes copied. Not present on error>, 2366// "net_error": <Network error code. Only present on error>, 2367// } 2368EVENT_TYPE(SIMPLE_CACHE_ENTRY_WRITE_END) 2369 2370// This event is created when DoomEntry is called. It contains no parameters. 2371EVENT_TYPE(SIMPLE_CACHE_ENTRY_DOOM_CALL) 2372 2373// This event is created when the Simple Cache actually starts dooming a cache 2374// entry. It contains no parameters. 2375EVENT_TYPE(SIMPLE_CACHE_ENTRY_DOOM_BEGIN) 2376 2377// This event is created when the Simple Cache finishes dooming an entry. 2378EVENT_TYPE(SIMPLE_CACHE_ENTRY_DOOM_END) 2379 2380// This event is created when CloseEntry is called. It contains no parameters. 2381// A Close call may not result in CLOSE_BEGIN and CLOSE_END if there are still 2382// more references to the entry remaining. 2383EVENT_TYPE(SIMPLE_CACHE_ENTRY_CLOSE_CALL) 2384 2385// This event is created when the Simple Cache actually starts closing a cache 2386// entry. It contains no parameters. 2387EVENT_TYPE(SIMPLE_CACHE_ENTRY_CLOSE_BEGIN) 2388 2389// This event is created when the Simple Cache finishes a CloseEntry call. It 2390// contains no parameters. 2391EVENT_TYPE(SIMPLE_CACHE_ENTRY_CLOSE_END) 2392 2393// This event is created (in a source of the same name) when the internal DNS 2394// resolver creates a UDP socket to check for global IPv6 connectivity. 2395EVENT_TYPE(IPV6_REACHABILITY_CHECK) 2396