libosmovty 1.9.0.196-9975
Osmocom VTY library
Telnet Interface

Files

file  telnet_interface.h
 minimalistic telnet/network interface it might turn into a wire interface
 

Data Structures

struct  telnet_connection
 A telnet connection. More...
 

Functions

int telnet_init_default (void *tall_ctx, void *priv, int default_port)
 Initializes telnet based VTY interface using the configured bind addr/port. More...
 
int telnet_init (void *tall_ctx, void *priv, int port) OSMO_DEPRECATED("This function ignores dynamic port configuration. Use telnet_init_default() instead")
 Initialize telnet based VTY interface listening to 127.0.0.1. More...
 
int telnet_init_dynif (void *tall_ctx, void *priv, const char *ip, int port) OSMO_DEPRECATED("This function ignores dynamic port configuration. Use telnet_init_default() instead")
 Initialize telnet based VTY interface. More...
 
void telnet_exit (void)
 Close all telnet connections and release the telnet socket. More...
 

Detailed Description

Function Documentation

◆ telnet_exit()

void telnet_exit ( void  )

Close all telnet connections and release the telnet socket.

References entry, osmo_fd::fd, telnet_connection::fd, llist_for_each_entry_safe, osmo_fd_unregister(), server_socket, tall_telnet_ctx, and telnet_close_client().

◆ telnet_init()

int telnet_init ( void *  tall_ctx,
void *  priv,
int  port 
)

Initialize telnet based VTY interface listening to 127.0.0.1.

Parameters
[in]tall_ctxtalloc context
[in]privprivate data to be passed to callback
[in]portTCP port number to bind to
Deprecated:
use telnet_init_default() instead

References _telnet_init_dynif().

◆ telnet_init_default()

int telnet_init_default ( void *  tall_ctx,
void *  priv,
int  default_port 
)

Initializes telnet based VTY interface using the configured bind addr/port.

Parameters
[in]tall_ctxtalloc context
[in]privprivate data to be passed to callback
[in]default_portTCP port number to bind to if not explicitly configured

References _telnet_init_dynif(), vty_get_bind_addr(), and vty_get_bind_port().

◆ telnet_init_dynif()

int telnet_init_dynif ( void *  tall_ctx,
void *  priv,
const char *  ip,
int  port 
)

Initialize telnet based VTY interface.

Parameters
[in]tall_ctxtalloc context
[in]privprivate data to be passed to callback
[in]ipIP to listen to ('::1' for localhost, '::0' for all, ...)
[in]portTCP port number to bind to
Deprecated:
use telnet_init_default() instead

References _telnet_init_dynif().