3 * Definitions for capture file summary data
5 * Wireshark - Network traffic analyzer
6 * By Gerald Combs <gerald@wireshark.org>
7 * Copyright 1998 Gerald Combs
9 * SPDX-License-Identifier: GPL-2.0-or-later
16 #include "ui/capture.h"
21 #endif /* __cplusplus */
23 typedef struct iface_summary_info_tag
{
28 uint64_t drops
; /**< number of packet drops */
29 bool drops_known
; /**< true if number of packet drops is known */
30 int snap
; /**< Maximum captured packet length; 0 if not known */
31 int encap_type
; /**< wiretap encapsulation type */
34 #define HASH_STR_SIZE (65) /* Max hash size * 2 + '\0' */
36 typedef struct _summary_tally
{
37 uint64_t bytes
; /**< total bytes */
38 double start_time
; /**< seconds, with msec resolution */
39 double stop_time
; /**< seconds, with msec resolution */
40 double elapsed_time
; /**< seconds, with msec resolution,
41 includes time before first packet
42 and after last packet */
43 uint32_t marked_count
; /**< number of marked packets */
44 uint32_t marked_count_ts
; /**< number of time-stamped marked packets */
45 uint64_t marked_bytes
; /**< total bytes in the marked packets */
46 double marked_start
; /**< time in seconds, with msec resolution */
47 double marked_stop
; /**< time in seconds, with msec resolution */
48 uint32_t ignored_count
; /**< number of ignored packets */
49 uint32_t packet_count
; /**< total number of packets in trace */
50 uint32_t packet_count_ts
; /**< total number of time-stamped packets in trace */
51 uint32_t filtered_count
; /**< number of filtered packets */
52 uint32_t filtered_count_ts
; /**< number of time-stamped filtered packets */
53 uint64_t filtered_bytes
; /**< total bytes in the filtered packets */
54 double filtered_start
; /**< time in seconds, with msec resolution */
55 double filtered_stop
; /**< time in seconds, with msec resolution */
56 const char *filename
; /**< path of capture file */
57 int64_t file_length
; /**< file length in bytes */
58 char file_sha256
[HASH_STR_SIZE
]; /**< SHA256 hash of capture file */
59 char file_sha1
[HASH_STR_SIZE
]; /**< SHA1 hash of capture file */
60 int file_type
; /**< wiretap file type */
61 wtap_compression_type compression_type
; /**< compression type of file, or uncompressed */
62 int file_encap_type
; /**< wiretap encapsulation type for file */
63 GArray
*packet_encap_types
; /**< wiretap encapsulation types for packets */
64 int snap
; /**< Maximum captured packet length; 0 if not known */
65 bool drops_known
; /**< true if number of packet drops is known */
66 uint64_t drops
; /**< number of packet drops */
67 const char *dfilter
; /**< display filter */
69 /* capture related, use summary_fill_in_capture() to get values */
75 summary_fill_in(capture_file
*cf
, summary_tally
*st
);
79 summary_fill_in_capture(capture_file
*cf
, capture_options
*capture_opts
, summary_tally
*st
);
84 #endif /* __cplusplus */
86 #endif /* summary.h */