mirror of
https://github.com/monero-project/monero.git
synced 2025-07-29 23:28:41 -04:00
Upgrade unbound library
These files were pulled from the 1.6.3 release tarball. This new version builds against OpenSSL version 1.1 which will be the default in the new Debian Stable which is due to be released RealSoonNow (tm).
This commit is contained in:
parent
e3da0ca828
commit
a85b5759f3
241 changed files with 33336 additions and 12049 deletions
153
external/unbound/util/fptr_wlist.c
vendored
153
external/unbound/util/fptr_wlist.c
vendored
|
@ -51,6 +51,7 @@
|
|||
#include "services/localzone.h"
|
||||
#include "services/cache/infra.h"
|
||||
#include "services/cache/rrset.h"
|
||||
#include "services/view.h"
|
||||
#include "dns64/dns64.h"
|
||||
#include "iterator/iterator.h"
|
||||
#include "iterator/iter_fwd.h"
|
||||
|
@ -74,13 +75,20 @@
|
|||
#ifdef UB_ON_WINDOWS
|
||||
#include "winrc/win_svc.h"
|
||||
#endif
|
||||
#include "respip/respip.h"
|
||||
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
#include "pythonmod/pythonmod.h"
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
#include "cachedb/cachedb.h"
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
#include "edns-subnet/subnetmod.h"
|
||||
#endif
|
||||
|
||||
int
|
||||
fptr_whitelist_comm_point(comm_point_callback_t *fptr)
|
||||
fptr_whitelist_comm_point(comm_point_callback_type *fptr)
|
||||
{
|
||||
if(fptr == &worker_handle_request) return 1;
|
||||
else if(fptr == &outnet_udp_cb) return 1;
|
||||
|
@ -90,7 +98,7 @@ fptr_whitelist_comm_point(comm_point_callback_t *fptr)
|
|||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_comm_point_raw(comm_point_callback_t *fptr)
|
||||
fptr_whitelist_comm_point_raw(comm_point_callback_type *fptr)
|
||||
{
|
||||
if(fptr == &tube_handle_listen) return 1;
|
||||
else if(fptr == &tube_handle_write) return 1;
|
||||
|
@ -152,7 +160,7 @@ fptr_whitelist_event(void (*fptr)(int, short, void *))
|
|||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_pending_udp(comm_point_callback_t *fptr)
|
||||
fptr_whitelist_pending_udp(comm_point_callback_type *fptr)
|
||||
{
|
||||
if(fptr == &serviced_udp_callback) return 1;
|
||||
else if(fptr == &worker_handle_reply) return 1;
|
||||
|
@ -161,7 +169,7 @@ fptr_whitelist_pending_udp(comm_point_callback_t *fptr)
|
|||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_pending_tcp(comm_point_callback_t *fptr)
|
||||
fptr_whitelist_pending_tcp(comm_point_callback_type *fptr)
|
||||
{
|
||||
if(fptr == &serviced_tcp_callback) return 1;
|
||||
else if(fptr == &worker_handle_reply) return 1;
|
||||
|
@ -170,7 +178,7 @@ fptr_whitelist_pending_tcp(comm_point_callback_t *fptr)
|
|||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_serviced_query(comm_point_callback_t *fptr)
|
||||
fptr_whitelist_serviced_query(comm_point_callback_type *fptr)
|
||||
{
|
||||
if(fptr == &worker_handle_service_reply) return 1;
|
||||
else if(fptr == &libworker_handle_service_reply) return 1;
|
||||
|
@ -200,47 +208,54 @@ fptr_whitelist_rbtree_cmp(int (*fptr) (const void *, const void *))
|
|||
else if(fptr == &val_neg_zone_compare) return 1;
|
||||
else if(fptr == &probetree_cmp) return 1;
|
||||
else if(fptr == &replay_var_compare) return 1;
|
||||
else if(fptr == &view_cmp) return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_hash_sizefunc(lruhash_sizefunc_t fptr)
|
||||
fptr_whitelist_hash_sizefunc(lruhash_sizefunc_type fptr)
|
||||
{
|
||||
if(fptr == &msgreply_sizefunc) return 1;
|
||||
else if(fptr == &ub_rrset_sizefunc) return 1;
|
||||
else if(fptr == &infra_sizefunc) return 1;
|
||||
else if(fptr == &key_entry_sizefunc) return 1;
|
||||
else if(fptr == &rate_sizefunc) return 1;
|
||||
else if(fptr == &ip_rate_sizefunc) return 1;
|
||||
else if(fptr == &test_slabhash_sizefunc) return 1;
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &msg_cache_sizefunc) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_hash_compfunc(lruhash_compfunc_t fptr)
|
||||
fptr_whitelist_hash_compfunc(lruhash_compfunc_type fptr)
|
||||
{
|
||||
if(fptr == &query_info_compare) return 1;
|
||||
else if(fptr == &ub_rrset_compare) return 1;
|
||||
else if(fptr == &infra_compfunc) return 1;
|
||||
else if(fptr == &key_entry_compfunc) return 1;
|
||||
else if(fptr == &rate_compfunc) return 1;
|
||||
else if(fptr == &ip_rate_compfunc) return 1;
|
||||
else if(fptr == &test_slabhash_compfunc) return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_hash_delkeyfunc(lruhash_delkeyfunc_t fptr)
|
||||
fptr_whitelist_hash_delkeyfunc(lruhash_delkeyfunc_type fptr)
|
||||
{
|
||||
if(fptr == &query_entry_delete) return 1;
|
||||
else if(fptr == &ub_rrset_key_delete) return 1;
|
||||
else if(fptr == &infra_delkeyfunc) return 1;
|
||||
else if(fptr == &key_entry_delkeyfunc) return 1;
|
||||
else if(fptr == &rate_delkeyfunc) return 1;
|
||||
else if(fptr == &ip_rate_delkeyfunc) return 1;
|
||||
else if(fptr == &test_slabhash_delkey) return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_hash_deldatafunc(lruhash_deldatafunc_t fptr)
|
||||
fptr_whitelist_hash_deldatafunc(lruhash_deldatafunc_type fptr)
|
||||
{
|
||||
if(fptr == &reply_info_delete) return 1;
|
||||
else if(fptr == &rrset_data_delete) return 1;
|
||||
|
@ -248,11 +263,14 @@ fptr_whitelist_hash_deldatafunc(lruhash_deldatafunc_t fptr)
|
|||
else if(fptr == &key_entry_deldatafunc) return 1;
|
||||
else if(fptr == &rate_deldatafunc) return 1;
|
||||
else if(fptr == &test_slabhash_deldata) return 1;
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnet_data_delete) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
fptr_whitelist_hash_markdelfunc(lruhash_markdelfunc_t fptr)
|
||||
fptr_whitelist_hash_markdelfunc(lruhash_markdelfunc_type fptr)
|
||||
{
|
||||
if(fptr == NULL) return 1;
|
||||
else if(fptr == &rrset_markdel) return 1;
|
||||
|
@ -262,11 +280,9 @@ fptr_whitelist_hash_markdelfunc(lruhash_markdelfunc_t fptr)
|
|||
/** whitelist env->send_query callbacks */
|
||||
int
|
||||
fptr_whitelist_modenv_send_query(struct outbound_entry* (*fptr)(
|
||||
uint8_t* qname, size_t qnamelen, uint16_t qtype, uint16_t qclass,
|
||||
uint16_t flags, int dnssec, int want_dnssec, int nocaps,
|
||||
struct sockaddr_storage* addr, socklen_t addrlen,
|
||||
uint8_t* zone, size_t zonelen,
|
||||
struct module_qstate* q))
|
||||
struct query_info* qinfo, uint16_t flags, int dnssec, int want_dnssec,
|
||||
int nocaps, struct sockaddr_storage* addr, socklen_t addrlen,
|
||||
uint8_t* zone, size_t zonelen, int ssl_upstream, struct module_qstate* q))
|
||||
{
|
||||
if(fptr == &worker_send_query) return 1;
|
||||
else if(fptr == &libworker_send_query) return 1;
|
||||
|
@ -312,8 +328,15 @@ fptr_whitelist_mod_init(int (*fptr)(struct module_env* env, int id))
|
|||
if(fptr == &iter_init) return 1;
|
||||
else if(fptr == &val_init) return 1;
|
||||
else if(fptr == &dns64_init) return 1;
|
||||
else if(fptr == &respip_init) return 1;
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
else if(fptr == &pythonmod_init) return 1;
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
else if(fptr == &cachedb_init) return 1;
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnetmod_init) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
@ -324,8 +347,15 @@ fptr_whitelist_mod_deinit(void (*fptr)(struct module_env* env, int id))
|
|||
if(fptr == &iter_deinit) return 1;
|
||||
else if(fptr == &val_deinit) return 1;
|
||||
else if(fptr == &dns64_deinit) return 1;
|
||||
else if(fptr == &respip_deinit) return 1;
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
else if(fptr == &pythonmod_deinit) return 1;
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
else if(fptr == &cachedb_deinit) return 1;
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnetmod_deinit) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
@ -337,8 +367,15 @@ fptr_whitelist_mod_operate(void (*fptr)(struct module_qstate* qstate,
|
|||
if(fptr == &iter_operate) return 1;
|
||||
else if(fptr == &val_operate) return 1;
|
||||
else if(fptr == &dns64_operate) return 1;
|
||||
else if(fptr == &respip_operate) return 1;
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
else if(fptr == &pythonmod_operate) return 1;
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
else if(fptr == &cachedb_operate) return 1;
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnetmod_operate) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
@ -350,8 +387,15 @@ fptr_whitelist_mod_inform_super(void (*fptr)(
|
|||
if(fptr == &iter_inform_super) return 1;
|
||||
else if(fptr == &val_inform_super) return 1;
|
||||
else if(fptr == &dns64_inform_super) return 1;
|
||||
else if(fptr == &respip_inform_super) return 1;
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
else if(fptr == &pythonmod_inform_super) return 1;
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
else if(fptr == &cachedb_inform_super) return 1;
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnetmod_inform_super) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
@ -363,8 +407,15 @@ fptr_whitelist_mod_clear(void (*fptr)(struct module_qstate* qstate,
|
|||
if(fptr == &iter_clear) return 1;
|
||||
else if(fptr == &val_clear) return 1;
|
||||
else if(fptr == &dns64_clear) return 1;
|
||||
else if(fptr == &respip_clear) return 1;
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
else if(fptr == &pythonmod_clear) return 1;
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
else if(fptr == &cachedb_clear) return 1;
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnetmod_clear) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
@ -375,8 +426,15 @@ fptr_whitelist_mod_get_mem(size_t (*fptr)(struct module_env* env, int id))
|
|||
if(fptr == &iter_get_mem) return 1;
|
||||
else if(fptr == &val_get_mem) return 1;
|
||||
else if(fptr == &dns64_get_mem) return 1;
|
||||
else if(fptr == &respip_get_mem) return 1;
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
else if(fptr == &pythonmod_get_mem) return 1;
|
||||
#endif
|
||||
#ifdef USE_CACHEDB
|
||||
else if(fptr == &cachedb_get_mem) return 1;
|
||||
#endif
|
||||
#ifdef CLIENT_SUBNET
|
||||
else if(fptr == &subnetmod_get_mem) return 1;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
@ -388,14 +446,14 @@ fptr_whitelist_alloc_cleanup(void (*fptr)(void*))
|
|||
return 0;
|
||||
}
|
||||
|
||||
int fptr_whitelist_tube_listen(tube_callback_t* fptr)
|
||||
int fptr_whitelist_tube_listen(tube_callback_type* fptr)
|
||||
{
|
||||
if(fptr == &worker_handle_control_cmd) return 1;
|
||||
else if(fptr == &libworker_handle_control_cmd) return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int fptr_whitelist_mesh_cb(mesh_cb_func_t fptr)
|
||||
int fptr_whitelist_mesh_cb(mesh_cb_func_type fptr)
|
||||
{
|
||||
if(fptr == &libworker_fg_done_cb) return 1;
|
||||
else if(fptr == &libworker_bg_done_cb) return 1;
|
||||
|
@ -411,3 +469,64 @@ int fptr_whitelist_print_func(void (*fptr)(char*,void*))
|
|||
else if(fptr == &remote_get_opt_ssl) return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int fptr_whitelist_inplace_cb_reply_generic(inplace_cb_reply_func_type* fptr,
|
||||
enum inplace_cb_list_type type)
|
||||
{
|
||||
#ifndef WITH_PYTHONMODULE
|
||||
(void)fptr;
|
||||
#endif
|
||||
if(type == inplace_cb_reply) {
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
if(fptr == &python_inplace_cb_reply_generic) return 1;
|
||||
#endif
|
||||
} else if(type == inplace_cb_reply_cache) {
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
if(fptr == &python_inplace_cb_reply_generic) return 1;
|
||||
#endif
|
||||
} else if(type == inplace_cb_reply_local) {
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
if(fptr == &python_inplace_cb_reply_generic) return 1;
|
||||
#endif
|
||||
} else if(type == inplace_cb_reply_servfail) {
|
||||
#ifdef WITH_PYTHONMODULE
|
||||
if(fptr == &python_inplace_cb_reply_generic) return 1;
|
||||
#endif
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
int fptr_whitelist_inplace_cb_query(inplace_cb_query_func_type* fptr)
|
||||
{
|
||||
#ifdef CLIENT_SUBNET
|
||||
if(fptr == &ecs_whitelist_check)
|
||||
return 1;
|
||||
#else
|
||||
(void)fptr;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
int fptr_whitelist_inplace_cb_edns_back_parsed(
|
||||
inplace_cb_edns_back_parsed_func_type* fptr)
|
||||
{
|
||||
#ifdef CLIENT_SUBNET
|
||||
if(fptr == &ecs_edns_back_parsed)
|
||||
return 1;
|
||||
#else
|
||||
(void)fptr;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
int fptr_whitelist_inplace_cb_query_response(
|
||||
inplace_cb_query_response_func_type* fptr)
|
||||
{
|
||||
#ifdef CLIENT_SUBNET
|
||||
if(fptr == &ecs_query_response)
|
||||
return 1;
|
||||
#else
|
||||
(void)fptr;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue