networkclient
|
#include <client.h>
Data Fields | |
int | sockfd |
int | code |
struct sockaddr_storage | src |
struct sockaddr_storage | dst |
socklen_t | sizeof_addr |
const char * | secret |
size_t | sizeof_secret |
int | used |
void * | ctx |
int(* | packet_send )(void *, RADIUS_PACKET *) |
nr_retransmit_config_t | timers |
RADIUS_PACKET * | ids [256] |
Track packets sent to a server.
This data structure tracks Identifiers which are used to communicate with a particular destination server. The application should call nr_track_id_init() to initialize it. If necessary, the application should then call nr_track_id_set_ipv4() to open an IPv4 socket to the server.
If the RADIUS packets are being transported over an encapsulation layer (e.g. RADIUS over TLS), then nr_track_id_set_ipv4() does not need to be called. The nr_track_id_t structure should instead be associated wih the TLS session / socket.
int nr_track_id_t::code |
default value for the Code
Referenced by nr_track_id_alloc(), nr_track_id_init(), and nr_track_id_packet_alloc().
void* nr_track_id_t::ctx |
Context for packet_send
Referenced by nr_track_id_init(), and nr_track_id_socket().
struct sockaddr_storage nr_track_id_t::dst |
Destination address of the packet
Referenced by nr_track_id_alloc(), nr_track_id_init(), and nr_track_id_socket().
RADIUS_PACKET* nr_track_id_t::ids[256] |
Pointers to "in flight" packets
Referenced by nr_track_id_alloc(), nr_track_id_realloc(), and nr_track_id_release().
int(* nr_track_id_t::packet_send) (void *, RADIUS_PACKET *) |
function to send a packet
Referenced by nr_track_id_init(), and nr_track_id_socket().
const char* nr_track_id_t::secret |
The shared secret
Referenced by nr_track_id_init(), nr_track_id_packet_alloc(), nr_track_id_socket(), and nr_transmit_init().
socklen_t nr_track_id_t::sizeof_addr |
the size of the address field (v4 or v6)
size_t nr_track_id_t::sizeof_secret |
Length of the shared secret
Referenced by nr_track_id_init(), nr_track_id_socket(), and nr_transmit_init().
int nr_track_id_t::sockfd |
socket for sending packets
Referenced by nr_track_id_alloc(), nr_track_id_close(), nr_track_id_init(), and nr_track_id_socket().
struct sockaddr_storage nr_track_id_t::src |
Source address of the packet
Referenced by nr_track_id_alloc(), nr_track_id_init(), and nr_track_id_socket().
nr_retransmit_config_t nr_track_id_t::timers |
Referenced by nr_track_id_init().
int nr_track_id_t::used |
Number of used IDs
Referenced by nr_track_id_alloc(), nr_track_id_close(), and nr_track_id_release().