|
Wireshark 4.7.0
The Wireshark network protocol analyzer
|
Go to the source code of this file.
Classes | |
| struct | _ssh_params |
| Holds the connection parameters required to establish an SSH session for an SSH-based extcap capture. More... | |
Macros | |
| #define | STDERR_FILENO 2 |
| #define | STDOUT_FILENO 1 |
| #define | SSH_BASE_OPTIONS |
| #define | SSH_BASE_PACKET_OPTIONS |
Typedefs | |
| typedef struct _ssh_params | ssh_params_t |
| Holds the connection parameters required to establish an SSH session for an SSH-based extcap capture. | |
Functions | |
| void | add_libssh_info (extcap_parameters *extcap_conf) |
| Adds information about the libssh library version to the extcap parameters. | |
| ssh_session | create_ssh_connection (const ssh_params_t *ssh_params, char **err_info) |
| Creates an SSH session based on the provided parameters. | |
| int | ssh_channel_printf (ssh_channel channel, const char *fmt,...) |
| Writes a formatted message to an SSH channel. | |
| void | ssh_cleanup (ssh_session *sshs, ssh_channel *channel) |
| Cleans up SSH session and channel resources. | |
| ssh_params_t * | ssh_params_new (void) |
| Create a new SSH parameters structure. | |
| void | ssh_params_free (ssh_params_t *ssh_params) |
| Frees the memory allocated for an ssh_params_t structure. | |
| void | ssh_params_set_log_level (ssh_params_t *ssh_params, enum ws_log_level level) |
| Set the log level for SSH parameters. | |
ssh-base has base utility functions to connect to hosts via ssh
Copyright 2016, Dario Lombardo
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
| #define SSH_BASE_OPTIONS |
| #define SSH_BASE_PACKET_OPTIONS |
| void add_libssh_info | ( | extcap_parameters * | extcap_conf | ) |
Adds information about the libssh library version to the extcap parameters.
| extcap_conf | Pointer to the extcap parameters structure. |
| ssh_session create_ssh_connection | ( | const ssh_params_t * | ssh_params, |
| char ** | err_info | ||
| ) |
Creates an SSH session based on the provided parameters.
Create a ssh connection using all the possible authentication methods
| ssh_params | Pointer to the SSH parameters structure containing connection details. |
| err_info | Pointer to a string that will hold error information if the function fails. |
| int ssh_channel_printf | ( | ssh_channel | channel, |
| const char * | fmt, | ||
| ... | |||
| ) |
Writes a formatted message to an SSH channel.
| channel | The SSH channel to write to. |
| fmt | The format string for the message. |
| void ssh_cleanup | ( | ssh_session * | sshs, |
| ssh_channel * | channel | ||
| ) |
Cleans up SSH session and channel resources.
This function is responsible for properly closing and freeing the SSH session and channel resources.
| sshs | Pointer to the SSH session to be cleaned up. |
| channel | Pointer to the SSH channel to be closed. |
| void ssh_params_free | ( | ssh_params_t * | ssh_params | ) |
Frees the memory allocated for an ssh_params_t structure.
| ssh_params | Pointer to the ssh_params_t structure to be freed. |
| ssh_params_t * ssh_params_new | ( | void | ) |
Create a new SSH parameters structure.
| void ssh_params_set_log_level | ( | ssh_params_t * | ssh_params, |
| enum ws_log_level | level | ||
| ) |
Set the log level for SSH parameters.
| ssh_params | Pointer to the SSH parameters structure. |
| level | The desired log level from the ws_log_level enumeration. |