fr_packet_t alloc/free functions
More...
#include <freeradius-devel/util/atexit.h>
#include <freeradius-devel/util/pair_legacy.h>
#include <freeradius-devel/server/packet.h>
Go to the source code of this file.
|
static int | _packet_global_free (UNUSED void *uctx) |
|
static int | _packet_global_init (UNUSED void *uctx) |
|
void | fr_packet_net_from_pairs (fr_packet_t *packet, fr_pair_list_t const *list) |
| Convert pairs to information in a packet. More...
|
|
int | fr_packet_pairs_from_packet (TALLOC_CTX *ctx, fr_pair_list_t *list, fr_packet_t const *packet) |
| Allocate a "Net." struct with src/dst host and port. More...
|
|
static int | inet2pairs (TALLOC_CTX *ctx, fr_pair_list_t *list, fr_dict_attr_t const *attr_ip, fr_dict_attr_t const *attr_port, fr_ipaddr_t const *ipaddr, uint16_t port) |
|
int | packet_global_init (void) |
| Initialises the Net. More...
|
|
static void | pairs2inet (fr_ipaddr_t *ipaddr, uint16_t *port, fr_pair_list_t const *list, fr_dict_attr_t const *attr_ip, fr_dict_attr_t const *attr_port) |
|
fr_packet_t alloc/free functions
- Copyright
- 2023 Network RADIUS SAS (legal.nosp@m.@net.nosp@m.workr.nosp@m.adiu.nosp@m.s.com)
Definition in file packet.c.
◆ _packet_global_free()
static int _packet_global_free |
( |
UNUSED void * |
uctx | ) |
|
|
static |
◆ _packet_global_init()
static int _packet_global_init |
( |
UNUSED void * |
uctx | ) |
|
|
static |
◆ fr_packet_net_from_pairs()
Convert pairs to information in a packet.
- Parameters
-
packet | the packet to send |
list | the list to check for Net.* |
Definition at line 139 of file packet.c.
◆ fr_packet_pairs_from_packet()
Allocate a "Net." struct with src/dst host and port.
- Parameters
-
| ctx | The context in which the packet is allocated. |
[in] | list | fr_pair_list_t value to resolve to fr_packet_t. |
[out] | packet | The request packet. |
- Returns
- 0 on success
- <0 on error.
Definition at line 89 of file packet.c.
◆ inet2pairs()
◆ packet_global_init()
int packet_global_init |
( |
void |
| ) |
|
Initialises the Net.
packet attributes.
- Returns
- 0 on success.
- -1 on failure.
Definition at line 185 of file packet.c.
◆ pairs2inet()
◆ attr_net
◆ attr_net_dst
◆ attr_net_dst_ip
◆ attr_net_dst_port
◆ attr_net_src
◆ attr_net_src_ip
◆ attr_net_src_port
◆ attr_net_timestamp
◆ dict_freeradius
◆ util_packet_dict
Initial value:= {
{ NULL }
}
static fr_dict_t const * dict_freeradius
Definition at line 34 of file packet.c.
◆ util_packet_dict_attr
Initial value:= {
{ NULL }
}
static fr_dict_attr_t const * attr_net_src
static fr_dict_attr_t const * attr_net_dst_port
static fr_dict_attr_t const * attr_net_timestamp
static fr_dict_attr_t const * attr_net
static fr_dict_attr_t const * attr_net_dst
static fr_dict_attr_t const * attr_net_src_ip
static fr_dict_attr_t const * attr_net_dst_ip
static fr_dict_attr_t const * attr_net_src_port
@ FR_TYPE_TLV
Contains nested attributes.
@ FR_TYPE_UINT16
16 Bit unsigned integer.
@ FR_TYPE_DATE
Unix time stamp, always has value >2^31.
@ FR_TYPE_COMBO_IP_ADDR
IPv4 or IPv6 address depending on length.
Definition at line 49 of file packet.c.