Go to the source code of this file.
|
#define | EXTCAP_BOOLEAN_REGEX "^.*([yt1-9])" |
|
#define | EXTCAP_PIPE_PREFIX "wireshark_extcap" |
|
#define | EXTCAP_CONTROL_IN_PREFIX "wireshark_control_ext_to_ws" |
|
#define | EXTCAP_CONTROL_OUT_PREFIX "wireshark_control_ws_to_ext" |
|
#define | EXTCAP_ARGUMENT_CONFIG "--extcap-config" |
|
#define | EXTCAP_ARGUMENT_RELOAD_OPTION "--extcap-reload-option" |
|
#define | EXTCAP_ARGUMENT_LIST_INTERFACES "--extcap-interfaces" |
|
#define | EXTCAP_ARGUMENT_INTERFACE "--extcap-interface" |
|
#define | EXTCAP_ARGUMENT_LIST_DLTS "--extcap-dlts" |
|
#define | EXTCAP_ARGUMENT_VERSION "--extcap-version" |
|
#define | EXTCAP_ARGUMENT_RUN_CAPTURE "--capture" |
|
#define | EXTCAP_ARGUMENT_CAPTURE_FILTER "--extcap-capture-filter" |
|
#define | EXTCAP_ARGUMENT_RUN_PIPE "--fifo" |
|
#define | EXTCAP_ARGUMENT_CONTROL_IN "--extcap-control-in" |
|
#define | EXTCAP_ARGUMENT_CONTROL_OUT "--extcap-control-out" |
|
|
typedef struct _extcap_info | extcap_info |
|
typedef void(* | extcap_plugin_description_callback) (const char *, const char *, const char *, const char *, void *) |
|
|
enum | extcap_filter_status { EXTCAP_FILTER_UNKNOWN
, EXTCAP_FILTER_VALID
, EXTCAP_FILTER_INVALID
} |
|
Definitions for extcap external capture Copyright 2013, Mike Ryan miker.nosp@m.yan@.nosp@m.lackl.nosp@m.ustr.nosp@m.e.net
Wireshark - Network traffic analyzer By Gerald Combs geral.nosp@m.d@wi.nosp@m.resha.nosp@m.rk.o.nosp@m.rg Copyright 1998 Gerald Combs
SPDX-License-Identifier: GPL-2.0-or-later
◆ append_extcap_interface_list()
GList * append_extcap_interface_list |
( |
GList * |
list | ) |
|
Append a list of all extcap capture interfaces to the specified list. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
- Returns
- An updated list on success, an unchanged list on failure.
◆ extcap_cleanup()
void extcap_cleanup |
( |
void |
| ) |
|
Clean up global extcap stuff on program exit.
Releases the dynamic preference value pointers. Must not be called before prefs_cleanup since these pointers could still be in use.
◆ extcap_clear_interfaces()
void extcap_clear_interfaces |
( |
void |
| ) |
|
Remove all loaded extcap interfaces.
◆ extcap_dump_all()
void extcap_dump_all |
( |
void |
| ) |
|
Print information about all available extcap executables. Initializes the extcap interface list if that hasn't already been done.
◆ extcap_free_if_configuration()
void extcap_free_if_configuration |
( |
GList * |
list, |
|
|
bool |
free_args |
|
) |
| |
Frees the memory from extcap_get_if_configuration.
- Parameters
-
list | The list returned by extcap_get_if_configuration. |
free_args | true if all arguments in the list must be freed too or false if the ownership of the arguments is taken by the caller. |
◆ extcap_get_descriptions()
void extcap_get_descriptions |
( |
extcap_plugin_description_callback |
callback, |
|
|
void * |
callback_data |
|
) |
| |
Retrieves information about all available extcap executables. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
callback | The description callback routine. |
callback_data | Data to be passed to the callback routine. |
◆ extcap_get_help_for_ifname()
char * extcap_get_help_for_ifname |
( |
const char * |
ifname | ) |
|
Retrieves help information for an extcap interface. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | The extcap interface name. |
- Returns
- A help string on success or NULL on failure.
◆ extcap_get_if_configuration()
GList * extcap_get_if_configuration |
( |
const char * |
ifname | ) |
|
Returns the configuration for the given interface name, or an empty list, if no configuration has been found. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | The interface name. |
◆ extcap_get_if_configuration_values()
GList * extcap_get_if_configuration_values |
( |
const char * |
ifname, |
|
|
const char * |
argname, |
|
|
GHashTable * |
arguments |
|
) |
| |
Returns the configuration values for the given argument, or an empty list, if no values could been found. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | The interface name. |
argname | The name of the argument for which the values should be retrieved. |
◆ extcap_get_if_dlts()
Fetches the interface capabilities for the named extcap interface. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | The interface name. |
err_str | Set to NULL on success, error description on failure. |
- Returns
- The interface capabilities on success, NULL on failure.
◆ extcap_get_tool_by_ifname()
extcap_info * extcap_get_tool_by_ifname |
( |
const char * |
ifname | ) |
|
Retrieves information about an extcap interface. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | The extcap interface name. |
- Returns
- The extcap information on success, NULL on failure.
◆ extcap_get_tool_info()
extcap_info * extcap_get_tool_info |
( |
const char * |
toolname | ) |
|
Retrieves information about an extcap executable. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
- Returns
- The extcap information on success, NULL on failure.
◆ extcap_has_configuration()
bool extcap_has_configuration |
( |
const char * |
ifname | ) |
|
Checks to see if an interface has configurable options. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | Interface to check. |
◆ extcap_has_toolbar()
bool extcap_has_toolbar |
( |
const char * |
ifname | ) |
|
Checks to see if the interface has an associated toolbar. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | Interface to check. |
- Returns
- true if the interface has a toolbar, false otherwise.
◆ extcap_pref_for_argument()
Fetch an extcap preference for a given argument. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | The interface to check. |
arg | The command line argument to check. |
- Returns
- The associated preference on success, NULL on failure.
◆ extcap_register_preferences()
void extcap_register_preferences |
( |
void |
| ) |
|
Registers preferences for all interfaces. Initializes the extcap interface list if that hasn't already been done.
◆ extcap_request_stop()
Notify all extcaps that capture session should be stopped. Forcefully stop session if extcaps do not finish before timeout.
- Parameters
-
cap_session | Capture session. |
◆ extcap_requires_configuration()
bool extcap_requires_configuration |
( |
const char * |
ifname | ) |
|
Checks if an interface has configurable options and if all are configured. Returns true when the extcap interface has configurable options that required modification. (For example, when an argument is required but empty.) Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | Interface to check. |
◆ extcap_verify_capture_filter()
extcap_filter_status extcap_verify_capture_filter |
( |
const char * |
ifname, |
|
|
const char * |
filter, |
|
|
char ** |
err_str |
|
) |
| |
Check if the capture filter for the given interface name is valid. Initializes the extcap interface list if that hasn't already been done.
- Parameters
-
ifname | Interface to check |
filter | Capture filter to check |
err_str | Error string returned if filter is invalid |
- Returns
- Filter check status.