unbound 0.1
|
This file contains functions for base EDNS options. More...
#include "config.h"
#include "util/edns.h"
#include "util/config_file.h"
#include "util/netevent.h"
#include "util/net_help.h"
#include "util/regional.h"
#include "util/data/msgparse.h"
#include "util/data/msgreply.h"
Functions | |
struct edns_strings * | edns_strings_create (void) |
Create structure to hold EDNS strings. More... | |
void | edns_strings_delete (struct edns_strings *edns_strings) |
Delete EDNS strings structure. More... | |
static int | edns_strings_client_insert (struct edns_strings *edns_strings, struct sockaddr_storage *addr, socklen_t addrlen, int net, const char *string) |
int | edns_strings_apply_cfg (struct edns_strings *edns_strings, struct config_file *config) |
Add configured EDNS strings. More... | |
struct edns_string_addr * | edns_string_addr_lookup (rbtree_type *tree, struct sockaddr_storage *addr, socklen_t addrlen) |
Find string for address. More... | |
This file contains functions for base EDNS options.
struct edns_strings * edns_strings_create | ( | void | ) |
Create structure to hold EDNS strings.
References edns_strings_delete(), edns_strings::region, and regional_create().
Referenced by ub_ctx_create_nopipe().
void edns_strings_delete | ( | struct edns_strings * | edns_strings | ) |
Delete EDNS strings structure.
edns_strings | struct to delete |
References edns_strings::region, and regional_destroy().
Referenced by daemon_delete(), edns_strings_create(), ub_ctx_create(), and ub_ctx_delete().
int edns_strings_apply_cfg | ( | struct edns_strings * | edns_strings, |
struct config_file * | config | ||
) |
Add configured EDNS strings.
edns_strings | edns strings to apply config to |
config | struct containing EDNS strings configuration |
References addr_tree_init(), edns_strings::client_strings, config_file::edns_client_strings, log_assert, log_err(), netblockstrtoaddr(), config_str2list::next, edns_strings::region, regional_free_all(), config_str2list::str, and config_str2list::str2.
Referenced by context_finalize().
struct edns_string_addr * edns_string_addr_lookup | ( | rbtree_type * | tree, |
struct sockaddr_storage * | addr, | ||
socklen_t | addrlen | ||
) |
Find string for address.
tree | tree containing EDNS strings per address prefix. |
addr | address to use for tree lookup |
addrlen | length of address |
References addr_tree_lookup().
Referenced by outnet_serviced_query().