| Wireshark 4.7.3 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
dissect_opts.h
Go to the documentation of this file.
1
11
12
18
19#ifndef __DISSECT_OPTS_H__
20#define __DISSECT_OPTS_H__
21
22#ifdef __cplusplus
23 extern "C" {
24#endif /* __cplusplus */
25
26/*
27 * Long options.
28 * We do not currently have long options corresponding to all short
29 * options; we should probably pick appropriate option names for them.
30 */
31
33#define LONGOPT_DISABLE_PROTOCOL LONGOPT_BASE_DISSECTOR+1
35#define LONGOPT_ENABLE_HEURISTIC LONGOPT_BASE_DISSECTOR+2
37#define LONGOPT_DISABLE_HEURISTIC LONGOPT_BASE_DISSECTOR+3
39#define LONGOPT_ENABLE_PROTOCOL LONGOPT_BASE_DISSECTOR+4
41#define LONGOPT_ONLY_PROTOCOLS LONGOPT_BASE_DISSECTOR+5
43#define LONGOPT_DISABLE_ALL_PROTOCOLS LONGOPT_BASE_DISSECTOR+6
44
48#define LONGOPT_DISSECT_COMMON \
49 {"disable-protocol", ws_required_argument, NULL, LONGOPT_DISABLE_PROTOCOL }, \
50 {"enable-heuristic", ws_required_argument, NULL, LONGOPT_ENABLE_HEURISTIC }, \
51 {"disable-heuristic", ws_required_argument, NULL, LONGOPT_DISABLE_HEURISTIC }, \
52 {"enable-protocol", ws_required_argument, NULL, LONGOPT_ENABLE_PROTOCOL }, \
53 {"only-protocols", ws_required_argument, NULL, LONGOPT_ONLY_PROTOCOLS }, \
54 {"disable-all-protocols", ws_no_argument, NULL, LONGOPT_DISABLE_ALL_PROTOCOLS }, \
55 {"read-filter", ws_required_argument, NULL, 'R' }, \
56 {"display-filter", ws_required_argument, NULL, 'Y' }, \
57
58
61#define OPTSTRING_DISSECT_COMMON \
62 "d:K:nN:R:t:u:Y:"
63
67 typedef struct dissect_options_tag {
68 ts_type time_format;
69 ts_precision time_precision;
70 GSList *enable_protocol_slist;
71 GSList *disable_protocol_slist;
72 GSList *enable_heur_slist;
73 GSList *disable_heur_slist;
74} dissect_options;
75
79 extern dissect_options global_dissect_options;
80
90 extern bool
91 dissect_opts_handle_opt(int opt, char *optarg_str_p);
92
99 extern bool
100 setup_enabled_and_disabled_protocols(void);
101
102#ifdef __cplusplus
103}
104#endif /* __cplusplus */
105
106#endif /* dissect_opts.h */
setup_enabled_and_disabled_protocols
bool setup_enabled_and_disabled_protocols(void)
Set up disabled protocols and enabled/disabled heuristic protocols as per specified command-line opti...
Definition dissect_opts.c:246
dissect_opts_handle_opt
bool dissect_opts_handle_opt(int opt, char *optarg_str_p)
Handle a command line option.
Definition dissect_opts.c:45
dissect_options
struct dissect_options_tag dissect_options
Capture options coming from user interface.
dissect_options_tag
Capture options coming from user interface.
Definition dissect_opts.h:67
dissect_options_tag::disable_heur_slist
GSList * disable_heur_slist
Definition dissect_opts.h:73
dissect_options_tag::enable_heur_slist
GSList * enable_heur_slist
Definition dissect_opts.h:72
dissect_options_tag::time_format
ts_type time_format
Definition dissect_opts.h:68
dissect_options_tag::disable_protocol_slist
GSList * disable_protocol_slist
Definition dissect_opts.h:71
dissect_options_tag::time_precision
ts_precision time_precision
Definition dissect_opts.h:69
dissect_options_tag::enable_protocol_slist
GSList * enable_protocol_slist
Definition dissect_opts.h:70
ts_precision
ts_precision
Sub-second precision used when formatting packet timestamps.
Definition timestamp.h:41
ts_type
ts_type
Format used to display packet timestamps in the summary packet list.
Definition timestamp.h:22