| Wireshark 4.7.0 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
plugins.h
Go to the documentation of this file.
1
11#ifndef __PLUGINS_H__
12#define __PLUGINS_H__
13
14#include <wireshark.h>
15
16#ifdef __cplusplus
17 extern "C" {
18#endif /* __cplusplus */
19
20 typedef void (*plugin_register_func)(void);
21 typedef uint32_t (*plugin_describe_func)(void);
22
23 typedef void plugins_t;
24
25 typedef enum {
26 WS_PLUGIN_EPAN,
27 WS_PLUGIN_WIRETAP,
28 WS_PLUGIN_CODEC,
29 WS_PLUGIN_UI
30} plugin_type_e;
31
32#define WS_PLUGIN_DESC_DISSECTOR (1UL << 0)
33#define WS_PLUGIN_DESC_FILE_TYPE (1UL << 1)
34#define WS_PLUGIN_DESC_CODEC (1UL << 2)
35#define WS_PLUGIN_DESC_EPAN (1UL << 3)
36#define WS_PLUGIN_DESC_TAP_LISTENER (1UL << 4)
37#define WS_PLUGIN_DESC_DFILTER (1UL << 5)
38#define WS_PLUGIN_DESC_UI (1UL << 6)
39
49WS_DLL_PUBLIC plugins_t *plugins_init(plugin_type_e type, const char* app_env_var_prefix);
50
51 typedef void (*plugin_description_callback)(const char *name, const char *version,
52 uint32_t flags, const char *filename,
53 void *user_data);
54
55WS_DLL_PUBLIC void plugins_get_descriptions(plugin_description_callback callback, void *user_data);
56
57WS_DLL_PUBLIC void plugins_dump_all(void);
58
59WS_DLL_PUBLIC int plugins_get_count(void);
60
61WS_DLL_PUBLIC void plugins_cleanup(plugins_t *plugins);
62
63WS_DLL_PUBLIC bool plugins_supported(void);
64
71WS_DLL_PUBLIC bool is_plugin_filename(const char *filename);
72
73#ifdef __cplusplus
74}
75#endif /* __cplusplus */
76
77#endif /* __PLUGINS_H__ */
78
79/*
80 * Editor modelines
81 *
82 * Local Variables:
83 * c-basic-offset: 4
84 * tab-width: 8
85 * indent-tabs-mode: nil
86 * End:
87 *
88 * ex: set shiftwidth=4 tabstop=8 expandtab:
89 * :indentSize=4:tabSize=8:noTabs=true:
90 */
plugins_init
WS_DLL_PUBLIC plugins_t * plugins_init(plugin_type_e type, const char *app_env_var_prefix)
Initialize plugins of a specific type.
Definition plugins.c:256
is_plugin_filename
WS_DLL_PUBLIC bool is_plugin_filename(const char *filename)
Returns true if the given filename ends in .dll on Windows or .so on other platforms.
Definition plugins.c:140