Classes | Macros | Typedefs | Functions
ares.h File Reference
#include "ares_version.h"
#include "ares_build.h"
#include "ares_rules.h"
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
Include dependency graph for ares.h:

Go to the source code of this file.

Classes

struct  ares_addr6ttl
 
struct  ares_addr_node
 
struct  ares_addr_port_node
 
struct  ares_addrinfo
 
struct  ares_addrinfo_cname
 
struct  ares_addrinfo_hints
 
struct  ares_addrinfo_node
 
struct  ares_addrttl
 
struct  ares_caa_reply
 
struct  ares_in6_addr
 
struct  ares_mx_reply
 
struct  ares_naptr_reply
 
struct  ares_options
 
struct  ares_soa_reply
 
struct  ares_socket_functions
 
struct  ares_srv_reply
 
struct  ares_txt_ext
 
struct  ares_txt_reply
 

Macros

#define ARES_AI_ADDRCONFIG   (1 << 6)
 
#define ARES_AI_ALL   (1 << 5)
 
#define ARES_AI_CANONIDN   (1 << 13)
 
#define ARES_AI_CANONNAME   (1 << 0)
 
#define ARES_AI_ENVHOSTS   (1 << 8)
 
#define ARES_AI_IDN   (1 << 10)
 
#define ARES_AI_IDN_ALLOW_UNASSIGNED   (1 << 11)
 
#define ARES_AI_IDN_USE_STD3_ASCII_RULES   (1 << 12)
 
#define ARES_AI_MASK
 
#define ARES_AI_NOSORT   (1 << 7)
 
#define ARES_AI_NUMERICHOST   (1 << 1)
 
#define ARES_AI_NUMERICSERV   (1 << 3)
 
#define ARES_AI_PASSIVE   (1 << 2)
 
#define ARES_AI_V4MAPPED   (1 << 4)
 
#define ARES_EADDRGETNETWORKPARAMS   23 /* introduced in 1.7.0 */
 
#define ARES_EBADFAMILY   9
 
#define ARES_EBADFLAGS   18
 
#define ARES_EBADHINTS   20
 
#define ARES_EBADNAME   8
 
#define ARES_EBADQUERY   7
 
#define ARES_EBADRESP   10
 
#define ARES_EBADSTR   17
 
#define ARES_ECANCELLED   24 /* introduced in 1.7.0 */
 
#define ARES_ECONNREFUSED   11
 
#define ARES_EDESTRUCTION   16
 
#define ARES_EFILE   14
 
#define ARES_EFORMERR   2
 
#define ARES_ELOADIPHLPAPI   22 /* introduced in 1.7.0 */
 
#define ARES_ENODATA   1
 
#define ARES_ENOMEM   15
 
#define ARES_ENONAME   19
 
#define ARES_ENOTFOUND   4
 
#define ARES_ENOTIMP   5
 
#define ARES_ENOTINITIALIZED   21 /* introduced in 1.7.0 */
 
#define ARES_EOF   13
 
#define ARES_EREFUSED   6
 
#define ARES_ESERVFAIL   3
 
#define ARES_ESERVICE   25 /* introduced in 1.?.0 */
 
#define ARES_ETIMEOUT   12
 
#define ARES_FLAG_EDNS   (1 << 8)
 
#define ARES_FLAG_IGNTC   (1 << 2)
 
#define ARES_FLAG_NOALIASES   (1 << 6)
 
#define ARES_FLAG_NOCHECKRESP   (1 << 7)
 
#define ARES_FLAG_NORECURSE   (1 << 3)
 
#define ARES_FLAG_NOSEARCH   (1 << 5)
 
#define ARES_FLAG_PRIMARY   (1 << 1)
 
#define ARES_FLAG_STAYOPEN   (1 << 4)
 
#define ARES_FLAG_USEVC   (1 << 0)
 
#define ARES_GETSOCK_MAXNUM
 
#define ARES_GETSOCK_READABLE(bits, num)   (bits & (1<< (num)))
 
#define ARES_GETSOCK_WRITABLE(bits, num)
 
#define ARES_LIB_INIT_ALL   (ARES_LIB_INIT_WIN32)
 
#define ARES_LIB_INIT_NONE   (0)
 
#define ARES_LIB_INIT_WIN32   (1 << 0)
 
#define ARES_NI_DCCP   (1 << 6)
 
#define ARES_NI_DGRAM   (1 << 4)
 
#define ARES_NI_IDN   (1 << 10)
 
#define ARES_NI_IDN_ALLOW_UNASSIGNED   (1 << 11)
 
#define ARES_NI_IDN_USE_STD3_ASCII_RULES   (1 << 12)
 
#define ARES_NI_LOOKUPHOST   (1 << 8)
 
#define ARES_NI_LOOKUPSERVICE   (1 << 9)
 
#define ARES_NI_NAMEREQD   (1 << 2)
 
#define ARES_NI_NOFQDN   (1 << 0)
 
#define ARES_NI_NUMERICHOST   (1 << 1)
 
#define ARES_NI_NUMERICSCOPE   (1 << 7)
 
#define ARES_NI_NUMERICSERV   (1 << 3)
 
#define ARES_NI_SCTP   (1 << 5)
 
#define ARES_NI_TCP   0
 
#define ARES_NI_UDP   ARES_NI_DGRAM
 
#define ARES_OPT_DOMAINS   (1 << 7)
 
#define ARES_OPT_EDNSPSZ   (1 << 15)
 
#define ARES_OPT_FLAGS   (1 << 0)
 
#define ARES_OPT_LOOKUPS   (1 << 8)
 
#define ARES_OPT_NDOTS   (1 << 3)
 
#define ARES_OPT_NOROTATE   (1 << 16)
 
#define ARES_OPT_RESOLVCONF   (1 << 17)
 
#define ARES_OPT_ROTATE   (1 << 14)
 
#define ARES_OPT_SERVERS   (1 << 6)
 
#define ARES_OPT_SOCK_RCVBUF   (1 << 12)
 
#define ARES_OPT_SOCK_SNDBUF   (1 << 11)
 
#define ARES_OPT_SOCK_STATE_CB   (1 << 9)
 
#define ARES_OPT_SORTLIST   (1 << 10)
 
#define ARES_OPT_TCP_PORT   (1 << 5)
 
#define ARES_OPT_TIMEOUT   (1 << 1)
 
#define ARES_OPT_TIMEOUTMS   (1 << 13)
 
#define ARES_OPT_TRIES   (1 << 2)
 
#define ARES_OPT_UDP_PORT   (1 << 4)
 
#define ARES_SOCKET_BAD   -1
 
#define ares_socket_typedef
 
#define ARES_SUCCESS   0
 
#define CARES_EXTERN
 

Typedefs

typedef void(* ares_addrinfo_callback) (void *arg, int status, int timeouts, struct ares_addrinfo *res)
 
typedef void(* ares_callback) (void *arg, int status, int timeouts, unsigned char *abuf, int alen)
 
typedef struct ares_channeldataares_channel
 
typedef void(* ares_host_callback) (void *arg, int status, int timeouts, struct hostent *hostent)
 
typedef void(* ares_nameinfo_callback) (void *arg, int status, int timeouts, char *node, char *service)
 
typedef int(* ares_sock_config_callback) (ares_socket_t socket_fd, int type, void *data)
 
typedef int(* ares_sock_create_callback) (ares_socket_t socket_fd, int type, void *data)
 
typedef void(* ares_sock_state_cb) (void *data, ares_socket_t socket_fd, int readable, int writable)
 
typedef int ares_socket_t
 

Functions

CARES_EXTERN void ares_cancel (ares_channel channel)
 
CARES_EXTERN int ares_create_query (const char *name, int dnsclass, int type, unsigned short id, int rd, unsigned char **buf, int *buflen, int max_udp_size)
 
CARES_EXTERN void ares_destroy (ares_channel channel)
 
CARES_EXTERN void ares_destroy_options (struct ares_options *options)
 
CARES_EXTERN int ares_dup (ares_channel *dest, ares_channel src)
 
CARES_EXTERN int ares_expand_name (const unsigned char *encoded, const unsigned char *abuf, int alen, char **s, long *enclen)
 
CARES_EXTERN int ares_expand_string (const unsigned char *encoded, const unsigned char *abuf, int alen, unsigned char **s, long *enclen)
 
CARES_EXTERN int ares_fds (ares_channel channel, fd_set *read_fds, fd_set *write_fds)
 
CARES_EXTERN void ares_free_data (void *dataptr)
 
CARES_EXTERN void ares_free_hostent (struct hostent *host)
 
CARES_EXTERN void ares_free_string (void *str)
 
CARES_EXTERN void ares_freeaddrinfo (struct ares_addrinfo *ai)
 
CARES_EXTERN int ares_get_servers (ares_channel channel, struct ares_addr_node **servers)
 
CARES_EXTERN int ares_get_servers_ports (ares_channel channel, struct ares_addr_port_node **servers)
 
CARES_EXTERN void ares_getaddrinfo (ares_channel channel, const char *node, const char *service, const struct ares_addrinfo_hints *hints, ares_addrinfo_callback callback, void *arg)
 
CARES_EXTERN void ares_gethostbyaddr (ares_channel channel, const void *addr, int addrlen, int family, ares_host_callback callback, void *arg)
 
CARES_EXTERN void ares_gethostbyname (ares_channel channel, const char *name, int family, ares_host_callback callback, void *arg)
 
CARES_EXTERN int ares_gethostbyname_file (ares_channel channel, const char *name, int family, struct hostent **host)
 
CARES_EXTERN void ares_getnameinfo (ares_channel channel, const struct sockaddr *sa, ares_socklen_t salen, int flags, ares_nameinfo_callback callback, void *arg)
 
CARES_EXTERN int ares_getsock (ares_channel channel, ares_socket_t *socks, int numsocks)
 
const CARES_EXTERN char * ares_inet_ntop (int af, const void *src, char *dst, ares_socklen_t size)
 
CARES_EXTERN int ares_inet_pton (int af, const char *src, void *dst)
 
CARES_EXTERN int ares_init (ares_channel *channelptr)
 
CARES_EXTERN int ares_init_options (ares_channel *channelptr, struct ares_options *options, int optmask)
 
CARES_EXTERN void ares_library_cleanup (void)
 
CARES_EXTERN int ares_library_init (int flags)
 
CARES_EXTERN int ares_library_init_mem (int flags, void *(*amalloc)(size_t size), void(*afree)(void *ptr), void *(*arealloc)(void *ptr, size_t size))
 
CARES_EXTERN int ares_library_initialized (void)
 
CARES_EXTERN int ares_mkquery (const char *name, int dnsclass, int type, unsigned short id, int rd, unsigned char **buf, int *buflen)
 
CARES_EXTERN int ares_parse_a_reply (const unsigned char *abuf, int alen, struct hostent **host, struct ares_addrttl *addrttls, int *naddrttls)
 
CARES_EXTERN int ares_parse_aaaa_reply (const unsigned char *abuf, int alen, struct hostent **host, struct ares_addr6ttl *addrttls, int *naddrttls)
 
CARES_EXTERN int ares_parse_caa_reply (const unsigned char *abuf, int alen, struct ares_caa_reply **caa_out)
 
CARES_EXTERN int ares_parse_mx_reply (const unsigned char *abuf, int alen, struct ares_mx_reply **mx_out)
 
CARES_EXTERN int ares_parse_naptr_reply (const unsigned char *abuf, int alen, struct ares_naptr_reply **naptr_out)
 
CARES_EXTERN int ares_parse_ns_reply (const unsigned char *abuf, int alen, struct hostent **host)
 
CARES_EXTERN int ares_parse_ptr_reply (const unsigned char *abuf, int alen, const void *addr, int addrlen, int family, struct hostent **host)
 
CARES_EXTERN int ares_parse_soa_reply (const unsigned char *abuf, int alen, struct ares_soa_reply **soa_out)
 
CARES_EXTERN int ares_parse_srv_reply (const unsigned char *abuf, int alen, struct ares_srv_reply **srv_out)
 
CARES_EXTERN int ares_parse_txt_reply (const unsigned char *abuf, int alen, struct ares_txt_reply **txt_out)
 
CARES_EXTERN int ares_parse_txt_reply_ext (const unsigned char *abuf, int alen, struct ares_txt_ext **txt_out)
 
CARES_EXTERN void ares_process (ares_channel channel, fd_set *read_fds, fd_set *write_fds)
 
CARES_EXTERN void ares_process_fd (ares_channel channel, ares_socket_t read_fd, ares_socket_t write_fd)
 
CARES_EXTERN void ares_query (ares_channel channel, const char *name, int dnsclass, int type, ares_callback callback, void *arg)
 
CARES_EXTERN int ares_save_options (ares_channel channel, struct ares_options *options, int *optmask)
 
CARES_EXTERN void ares_search (ares_channel channel, const char *name, int dnsclass, int type, ares_callback callback, void *arg)
 
CARES_EXTERN void ares_send (ares_channel channel, const unsigned char *qbuf, int qlen, ares_callback callback, void *arg)
 
CARES_EXTERN void ares_set_local_dev (ares_channel channel, const char *local_dev_name)
 
CARES_EXTERN void ares_set_local_ip4 (ares_channel channel, unsigned int local_ip)
 
CARES_EXTERN void ares_set_local_ip6 (ares_channel channel, const unsigned char *local_ip6)
 
CARES_EXTERN int ares_set_servers (ares_channel channel, struct ares_addr_node *servers)
 
CARES_EXTERN int ares_set_servers_csv (ares_channel channel, const char *servers)
 
CARES_EXTERN int ares_set_servers_ports (ares_channel channel, struct ares_addr_port_node *servers)
 
CARES_EXTERN int ares_set_servers_ports_csv (ares_channel channel, const char *servers)
 
CARES_EXTERN void ares_set_socket_callback (ares_channel channel, ares_sock_create_callback callback, void *user_data)
 
CARES_EXTERN void ares_set_socket_configure_callback (ares_channel channel, ares_sock_config_callback callback, void *user_data)
 
CARES_EXTERN void ares_set_socket_functions (ares_channel channel, const struct ares_socket_functions *funcs, void *user_data)
 
CARES_EXTERN int ares_set_sortlist (ares_channel channel, const char *sortstr)
 
const CARES_EXTERN char * ares_strerror (int code)
 
CARES_EXTERN struct timevalares_timeout (ares_channel channel, struct timeval *maxtv, struct timeval *tv)
 
const CARES_EXTERN char * ares_version (int *version)
 

Macro Definition Documentation

◆ ARES_AI_ADDRCONFIG

#define ARES_AI_ADDRCONFIG   (1 << 6)

Definition at line 197 of file ares.h.

◆ ARES_AI_ALL

#define ARES_AI_ALL   (1 << 5)

Definition at line 196 of file ares.h.

◆ ARES_AI_CANONIDN

#define ARES_AI_CANONIDN   (1 << 13)

Definition at line 204 of file ares.h.

◆ ARES_AI_CANONNAME

#define ARES_AI_CANONNAME   (1 << 0)

Definition at line 191 of file ares.h.

◆ ARES_AI_ENVHOSTS

#define ARES_AI_ENVHOSTS   (1 << 8)

Definition at line 199 of file ares.h.

◆ ARES_AI_IDN

#define ARES_AI_IDN   (1 << 10)

Definition at line 201 of file ares.h.

◆ ARES_AI_IDN_ALLOW_UNASSIGNED

#define ARES_AI_IDN_ALLOW_UNASSIGNED   (1 << 11)

Definition at line 202 of file ares.h.

◆ ARES_AI_IDN_USE_STD3_ASCII_RULES

#define ARES_AI_IDN_USE_STD3_ASCII_RULES   (1 << 12)

Definition at line 203 of file ares.h.

◆ ARES_AI_MASK

#define ARES_AI_MASK
Value:
ARES_AI_NUMERICSERV|ARES_AI_V4MAPPED|ARES_AI_ALL| \
ARES_AI_ADDRCONFIG)

Definition at line 206 of file ares.h.

◆ ARES_AI_NOSORT

#define ARES_AI_NOSORT   (1 << 7)

Definition at line 198 of file ares.h.

◆ ARES_AI_NUMERICHOST

#define ARES_AI_NUMERICHOST   (1 << 1)

Definition at line 192 of file ares.h.

◆ ARES_AI_NUMERICSERV

#define ARES_AI_NUMERICSERV   (1 << 3)

Definition at line 194 of file ares.h.

◆ ARES_AI_PASSIVE

#define ARES_AI_PASSIVE   (1 << 2)

Definition at line 193 of file ares.h.

◆ ARES_AI_V4MAPPED

#define ARES_AI_V4MAPPED   (1 << 4)

Definition at line 195 of file ares.h.

◆ ARES_EADDRGETNETWORKPARAMS

#define ARES_EADDRGETNETWORKPARAMS   23 /* introduced in 1.7.0 */

Definition at line 133 of file ares.h.

◆ ARES_EBADFAMILY

#define ARES_EBADFAMILY   9

Definition at line 111 of file ares.h.

◆ ARES_EBADFLAGS

#define ARES_EBADFLAGS   18

Definition at line 122 of file ares.h.

◆ ARES_EBADHINTS

#define ARES_EBADHINTS   20

Definition at line 126 of file ares.h.

◆ ARES_EBADNAME

#define ARES_EBADNAME   8

Definition at line 110 of file ares.h.

◆ ARES_EBADQUERY

#define ARES_EBADQUERY   7

Definition at line 109 of file ares.h.

◆ ARES_EBADRESP

#define ARES_EBADRESP   10

Definition at line 112 of file ares.h.

◆ ARES_EBADSTR

#define ARES_EBADSTR   17

Definition at line 119 of file ares.h.

◆ ARES_ECANCELLED

#define ARES_ECANCELLED   24 /* introduced in 1.7.0 */

Definition at line 136 of file ares.h.

◆ ARES_ECONNREFUSED

#define ARES_ECONNREFUSED   11

Definition at line 113 of file ares.h.

◆ ARES_EDESTRUCTION

#define ARES_EDESTRUCTION   16

Definition at line 118 of file ares.h.

◆ ARES_EFILE

#define ARES_EFILE   14

Definition at line 116 of file ares.h.

◆ ARES_EFORMERR

#define ARES_EFORMERR   2

Definition at line 102 of file ares.h.

◆ ARES_ELOADIPHLPAPI

#define ARES_ELOADIPHLPAPI   22 /* introduced in 1.7.0 */

Definition at line 132 of file ares.h.

◆ ARES_ENODATA

#define ARES_ENODATA   1

Definition at line 101 of file ares.h.

◆ ARES_ENOMEM

#define ARES_ENOMEM   15

Definition at line 117 of file ares.h.

◆ ARES_ENONAME

#define ARES_ENONAME   19

Definition at line 125 of file ares.h.

◆ ARES_ENOTFOUND

#define ARES_ENOTFOUND   4

Definition at line 104 of file ares.h.

◆ ARES_ENOTIMP

#define ARES_ENOTIMP   5

Definition at line 105 of file ares.h.

◆ ARES_ENOTINITIALIZED

#define ARES_ENOTINITIALIZED   21 /* introduced in 1.7.0 */

Definition at line 129 of file ares.h.

◆ ARES_EOF

#define ARES_EOF   13

Definition at line 115 of file ares.h.

◆ ARES_EREFUSED

#define ARES_EREFUSED   6

Definition at line 106 of file ares.h.

◆ ARES_ESERVFAIL

#define ARES_ESERVFAIL   3

Definition at line 103 of file ares.h.

◆ ARES_ESERVICE

#define ARES_ESERVICE   25 /* introduced in 1.?.0 */

Definition at line 139 of file ares.h.

◆ ARES_ETIMEOUT

#define ARES_ETIMEOUT   12

Definition at line 114 of file ares.h.

◆ ARES_FLAG_EDNS

#define ARES_FLAG_EDNS   (1 << 8)

Definition at line 150 of file ares.h.

◆ ARES_FLAG_IGNTC

#define ARES_FLAG_IGNTC   (1 << 2)

Definition at line 144 of file ares.h.

◆ ARES_FLAG_NOALIASES

#define ARES_FLAG_NOALIASES   (1 << 6)

Definition at line 148 of file ares.h.

◆ ARES_FLAG_NOCHECKRESP

#define ARES_FLAG_NOCHECKRESP   (1 << 7)

Definition at line 149 of file ares.h.

◆ ARES_FLAG_NORECURSE

#define ARES_FLAG_NORECURSE   (1 << 3)

Definition at line 145 of file ares.h.

◆ ARES_FLAG_NOSEARCH

#define ARES_FLAG_NOSEARCH   (1 << 5)

Definition at line 147 of file ares.h.

◆ ARES_FLAG_PRIMARY

#define ARES_FLAG_PRIMARY   (1 << 1)

Definition at line 143 of file ares.h.

◆ ARES_FLAG_STAYOPEN

#define ARES_FLAG_STAYOPEN   (1 << 4)

Definition at line 146 of file ares.h.

◆ ARES_FLAG_USEVC

#define ARES_FLAG_USEVC   (1 << 0)

Definition at line 142 of file ares.h.

◆ ARES_GETSOCK_MAXNUM

#define ARES_GETSOCK_MAXNUM
Value:
16 /* ares_getsock() can return info about this
many sockets */

Definition at line 209 of file ares.h.

◆ ARES_GETSOCK_READABLE

#define ARES_GETSOCK_READABLE (   bits,
  num 
)    (bits & (1<< (num)))

Definition at line 210 of file ares.h.

◆ ARES_GETSOCK_WRITABLE

#define ARES_GETSOCK_WRITABLE (   bits,
  num 
)
Value:
(bits & (1 << ((num) + \

Definition at line 211 of file ares.h.

◆ ARES_LIB_INIT_ALL

#define ARES_LIB_INIT_ALL   (ARES_LIB_INIT_WIN32)

Definition at line 217 of file ares.h.

◆ ARES_LIB_INIT_NONE

#define ARES_LIB_INIT_NONE   (0)

Definition at line 215 of file ares.h.

◆ ARES_LIB_INIT_WIN32

#define ARES_LIB_INIT_WIN32   (1 << 0)

Definition at line 216 of file ares.h.

◆ ARES_NI_DCCP

#define ARES_NI_DCCP   (1 << 6)

Definition at line 181 of file ares.h.

◆ ARES_NI_DGRAM

#define ARES_NI_DGRAM   (1 << 4)

Definition at line 177 of file ares.h.

◆ ARES_NI_IDN

#define ARES_NI_IDN   (1 << 10)

Definition at line 186 of file ares.h.

◆ ARES_NI_IDN_ALLOW_UNASSIGNED

#define ARES_NI_IDN_ALLOW_UNASSIGNED   (1 << 11)

Definition at line 187 of file ares.h.

◆ ARES_NI_IDN_USE_STD3_ASCII_RULES

#define ARES_NI_IDN_USE_STD3_ASCII_RULES   (1 << 12)

Definition at line 188 of file ares.h.

◆ ARES_NI_LOOKUPHOST

#define ARES_NI_LOOKUPHOST   (1 << 8)

Definition at line 183 of file ares.h.

◆ ARES_NI_LOOKUPSERVICE

#define ARES_NI_LOOKUPSERVICE   (1 << 9)

Definition at line 184 of file ares.h.

◆ ARES_NI_NAMEREQD

#define ARES_NI_NAMEREQD   (1 << 2)

Definition at line 175 of file ares.h.

◆ ARES_NI_NOFQDN

#define ARES_NI_NOFQDN   (1 << 0)

Definition at line 173 of file ares.h.

◆ ARES_NI_NUMERICHOST

#define ARES_NI_NUMERICHOST   (1 << 1)

Definition at line 174 of file ares.h.

◆ ARES_NI_NUMERICSCOPE

#define ARES_NI_NUMERICSCOPE   (1 << 7)

Definition at line 182 of file ares.h.

◆ ARES_NI_NUMERICSERV

#define ARES_NI_NUMERICSERV   (1 << 3)

Definition at line 176 of file ares.h.

◆ ARES_NI_SCTP

#define ARES_NI_SCTP   (1 << 5)

Definition at line 180 of file ares.h.

◆ ARES_NI_TCP

#define ARES_NI_TCP   0

Definition at line 178 of file ares.h.

◆ ARES_NI_UDP

#define ARES_NI_UDP   ARES_NI_DGRAM

Definition at line 179 of file ares.h.

◆ ARES_OPT_DOMAINS

#define ARES_OPT_DOMAINS   (1 << 7)

Definition at line 160 of file ares.h.

◆ ARES_OPT_EDNSPSZ

#define ARES_OPT_EDNSPSZ   (1 << 15)

Definition at line 168 of file ares.h.

◆ ARES_OPT_FLAGS

#define ARES_OPT_FLAGS   (1 << 0)

Definition at line 153 of file ares.h.

◆ ARES_OPT_LOOKUPS

#define ARES_OPT_LOOKUPS   (1 << 8)

Definition at line 161 of file ares.h.

◆ ARES_OPT_NDOTS

#define ARES_OPT_NDOTS   (1 << 3)

Definition at line 156 of file ares.h.

◆ ARES_OPT_NOROTATE

#define ARES_OPT_NOROTATE   (1 << 16)

Definition at line 169 of file ares.h.

◆ ARES_OPT_RESOLVCONF

#define ARES_OPT_RESOLVCONF   (1 << 17)

Definition at line 170 of file ares.h.

◆ ARES_OPT_ROTATE

#define ARES_OPT_ROTATE   (1 << 14)

Definition at line 167 of file ares.h.

◆ ARES_OPT_SERVERS

#define ARES_OPT_SERVERS   (1 << 6)

Definition at line 159 of file ares.h.

◆ ARES_OPT_SOCK_RCVBUF

#define ARES_OPT_SOCK_RCVBUF   (1 << 12)

Definition at line 165 of file ares.h.

◆ ARES_OPT_SOCK_SNDBUF

#define ARES_OPT_SOCK_SNDBUF   (1 << 11)

Definition at line 164 of file ares.h.

◆ ARES_OPT_SOCK_STATE_CB

#define ARES_OPT_SOCK_STATE_CB   (1 << 9)

Definition at line 162 of file ares.h.

◆ ARES_OPT_SORTLIST

#define ARES_OPT_SORTLIST   (1 << 10)

Definition at line 163 of file ares.h.

◆ ARES_OPT_TCP_PORT

#define ARES_OPT_TCP_PORT   (1 << 5)

Definition at line 158 of file ares.h.

◆ ARES_OPT_TIMEOUT

#define ARES_OPT_TIMEOUT   (1 << 1)

Definition at line 154 of file ares.h.

◆ ARES_OPT_TIMEOUTMS

#define ARES_OPT_TIMEOUTMS   (1 << 13)

Definition at line 166 of file ares.h.

◆ ARES_OPT_TRIES

#define ARES_OPT_TRIES   (1 << 2)

Definition at line 155 of file ares.h.

◆ ARES_OPT_UDP_PORT

#define ARES_OPT_UDP_PORT   (1 << 4)

Definition at line 157 of file ares.h.

◆ ARES_SOCKET_BAD

#define ARES_SOCKET_BAD   -1

Definition at line 230 of file ares.h.

◆ ares_socket_typedef

#define ares_socket_typedef

Definition at line 232 of file ares.h.

◆ ARES_SUCCESS

#define ARES_SUCCESS   0

Definition at line 98 of file ares.h.

◆ CARES_EXTERN

#define CARES_EXTERN

Definition at line 94 of file ares.h.

Typedef Documentation

◆ ares_addrinfo_callback

typedef void(* ares_addrinfo_callback) (void *arg, int status, int timeouts, struct ares_addrinfo *res)

Definition at line 315 of file ares.h.

◆ ares_callback

typedef void(* ares_callback) (void *arg, int status, int timeouts, unsigned char *abuf, int alen)

Definition at line 290 of file ares.h.

◆ ares_channel

typedef struct ares_channeldata* ares_channel

Definition at line 288 of file ares.h.

◆ ares_host_callback

typedef void(* ares_host_callback) (void *arg, int status, int timeouts, struct hostent *hostent)

Definition at line 296 of file ares.h.

◆ ares_nameinfo_callback

typedef void(* ares_nameinfo_callback) (void *arg, int status, int timeouts, char *node, char *service)

Definition at line 301 of file ares.h.

◆ ares_sock_config_callback

typedef int(* ares_sock_config_callback) (ares_socket_t socket_fd, int type, void *data)

Definition at line 311 of file ares.h.

◆ ares_sock_create_callback

typedef int(* ares_sock_create_callback) (ares_socket_t socket_fd, int type, void *data)

Definition at line 307 of file ares.h.

◆ ares_sock_state_cb

typedef void(* ares_sock_state_cb) (void *data, ares_socket_t socket_fd, int readable, int writable)

Definition at line 235 of file ares.h.

◆ ares_socket_t

typedef int ares_socket_t

Definition at line 229 of file ares.h.

Function Documentation

◆ ares_cancel()

CARES_EXTERN void ares_cancel ( ares_channel  channel)

Definition at line 26 of file ares_cancel.c.

◆ ares_create_query()

CARES_EXTERN int ares_create_query ( const char *  name,
int  dnsclass,
int  type,
unsigned short  id,
int  rd,
unsigned char **  buf,
int buflen,
int  max_udp_size 
)

Definition at line 78 of file ares_create_query.c.

◆ ares_destroy()

CARES_EXTERN void ares_destroy ( ares_channel  channel)

Definition at line 43 of file ares_destroy.c.

◆ ares_destroy_options()

CARES_EXTERN void ares_destroy_options ( struct ares_options options)

Definition at line 25 of file ares_destroy.c.

◆ ares_dup()

CARES_EXTERN int ares_dup ( ares_channel dest,
ares_channel  src 
)

Definition at line 243 of file ares_init.c.

◆ ares_expand_name()

CARES_EXTERN int ares_expand_name ( const unsigned char *  encoded,
const unsigned char *  abuf,
int  alen,
char **  s,
long enclen 
)

Definition at line 203 of file ares_expand_name.c.

◆ ares_expand_string()

CARES_EXTERN int ares_expand_string ( const unsigned char *  encoded,
const unsigned char *  abuf,
int  alen,
unsigned char **  s,
long enclen 
)

Definition at line 33 of file ares_expand_string.c.

◆ ares_fds()

CARES_EXTERN int ares_fds ( ares_channel  channel,
fd_set *  read_fds,
fd_set *  write_fds 
)

Definition at line 23 of file ares_fds.c.

◆ ares_free_data()

CARES_EXTERN void ares_free_data ( void *  dataptr)

Definition at line 41 of file ares_data.c.

◆ ares_free_hostent()

CARES_EXTERN void ares_free_hostent ( struct hostent *  host)

Definition at line 26 of file ares_free_hostent.c.

◆ ares_free_string()

CARES_EXTERN void ares_free_string ( void *  str)

Definition at line 22 of file ares_free_string.c.

◆ ares_freeaddrinfo()

CARES_EXTERN void ares_freeaddrinfo ( struct ares_addrinfo ai)

Definition at line 52 of file ares_freeaddrinfo.c.

◆ ares_get_servers()

CARES_EXTERN int ares_get_servers ( ares_channel  channel,
struct ares_addr_node **  servers 
)

Definition at line 31 of file ares_options.c.

◆ ares_get_servers_ports()

CARES_EXTERN int ares_get_servers_ports ( ares_channel  channel,
struct ares_addr_port_node **  servers 
)

Definition at line 86 of file ares_options.c.

◆ ares_getaddrinfo()

CARES_EXTERN void ares_getaddrinfo ( ares_channel  channel,
const char *  node,
const char *  service,
const struct ares_addrinfo_hints hints,
ares_addrinfo_callback  callback,
void *  arg 
)

Definition at line 580 of file ares_getaddrinfo.c.

◆ ares_gethostbyaddr()

CARES_EXTERN void ares_gethostbyaddr ( ares_channel  channel,
const void *  addr,
int  addrlen,
int  family,
ares_host_callback  callback,
void *  arg 
)

Definition at line 58 of file ares_gethostbyaddr.c.

◆ ares_gethostbyname()

CARES_EXTERN void ares_gethostbyname ( ares_channel  channel,
const char *  name,
int  family,
ares_host_callback  callback,
void *  arg 
)

Definition at line 75 of file ares_gethostbyname.c.

◆ ares_gethostbyname_file()

CARES_EXTERN int ares_gethostbyname_file ( ares_channel  channel,
const char *  name,
int  family,
struct hostent **  host 
)

Definition at line 321 of file ares_gethostbyname.c.

◆ ares_getnameinfo()

CARES_EXTERN void ares_getnameinfo ( ares_channel  channel,
const struct sockaddr *  sa,
ares_socklen_t  salen,
int  flags,
ares_nameinfo_callback  callback,
void *  arg 
)

Definition at line 76 of file ares_getnameinfo.c.

◆ ares_getsock()

CARES_EXTERN int ares_getsock ( ares_channel  channel,
ares_socket_t socks,
int  numsocks 
)

Definition at line 20 of file ares_getsock.c.

◆ ares_inet_ntop()

const CARES_EXTERN char* ares_inet_ntop ( int  af,
const void *  src,
char *  dst,
ares_socklen_t  size 
)

Definition at line 56 of file inet_ntop.c.

◆ ares_inet_pton()

CARES_EXTERN int ares_inet_pton ( int  af,
const char *  src,
void *  dst 
)

Definition at line 418 of file inet_net_pton.c.

◆ ares_init()

CARES_EXTERN int ares_init ( ares_channel channelptr)

Definition at line 98 of file ares_init.c.

◆ ares_init_options()

CARES_EXTERN int ares_init_options ( ares_channel channelptr,
struct ares_options options,
int  optmask 
)

Definition at line 103 of file ares_init.c.

◆ ares_library_cleanup()

CARES_EXTERN void ares_library_cleanup ( void  )

Definition at line 171 of file ares_library_init.c.

◆ ares_library_init()

CARES_EXTERN int ares_library_init ( int  flags)

Definition at line 133 of file ares_library_init.c.

◆ ares_library_init_mem()

CARES_EXTERN int ares_library_init_mem ( int  flags,
void *(*)(size_t size amalloc,
void(*)(void *ptr afree,
void *(*)(void *ptr, size_t size arealloc 
)

Definition at line 156 of file ares_library_init.c.

◆ ares_library_initialized()

CARES_EXTERN int ares_library_initialized ( void  )

Definition at line 193 of file ares_library_init.c.

◆ ares_mkquery()

CARES_EXTERN int ares_mkquery ( const char *  name,
int  dnsclass,
int  type,
unsigned short  id,
int  rd,
unsigned char **  buf,
int buflen 
)

Definition at line 20 of file ares_mkquery.c.

◆ ares_parse_a_reply()

CARES_EXTERN int ares_parse_a_reply ( const unsigned char *  abuf,
int  alen,
struct hostent **  host,
struct ares_addrttl addrttls,
int naddrttls 
)

Definition at line 44 of file ares_parse_a_reply.c.

◆ ares_parse_aaaa_reply()

CARES_EXTERN int ares_parse_aaaa_reply ( const unsigned char *  abuf,
int  alen,
struct hostent **  host,
struct ares_addr6ttl addrttls,
int naddrttls 
)

Definition at line 46 of file ares_parse_aaaa_reply.c.

◆ ares_parse_caa_reply()

CARES_EXTERN int ares_parse_caa_reply ( const unsigned char *  abuf,
int  alen,
struct ares_caa_reply **  caa_out 
)

Definition at line 41 of file ares_parse_caa_reply.c.

◆ ares_parse_mx_reply()

CARES_EXTERN int ares_parse_mx_reply ( const unsigned char *  abuf,
int  alen,
struct ares_mx_reply **  mx_out 
)

Definition at line 38 of file ares_parse_mx_reply.c.

◆ ares_parse_naptr_reply()

CARES_EXTERN int ares_parse_naptr_reply ( const unsigned char *  abuf,
int  alen,
struct ares_naptr_reply **  naptr_out 
)

Definition at line 38 of file ares_parse_naptr_reply.c.

◆ ares_parse_ns_reply()

CARES_EXTERN int ares_parse_ns_reply ( const unsigned char *  abuf,
int  alen,
struct hostent **  host 
)

Definition at line 39 of file ares_parse_ns_reply.c.

◆ ares_parse_ptr_reply()

CARES_EXTERN int ares_parse_ptr_reply ( const unsigned char *  abuf,
int  alen,
const void *  addr,
int  addrlen,
int  family,
struct hostent **  host 
)

Definition at line 37 of file ares_parse_ptr_reply.c.

◆ ares_parse_soa_reply()

CARES_EXTERN int ares_parse_soa_reply ( const unsigned char *  abuf,
int  alen,
struct ares_soa_reply **  soa_out 
)

Definition at line 38 of file ares_parse_soa_reply.c.

◆ ares_parse_srv_reply()

CARES_EXTERN int ares_parse_srv_reply ( const unsigned char *  abuf,
int  alen,
struct ares_srv_reply **  srv_out 
)

Definition at line 38 of file ares_parse_srv_reply.c.

◆ ares_parse_txt_reply()

CARES_EXTERN int ares_parse_txt_reply ( const unsigned char *  abuf,
int  alen,
struct ares_txt_reply **  txt_out 
)

Definition at line 202 of file ares_parse_txt_reply.c.

◆ ares_parse_txt_reply_ext()

CARES_EXTERN int ares_parse_txt_reply_ext ( const unsigned char *  abuf,
int  alen,
struct ares_txt_ext **  txt_out 
)

Definition at line 210 of file ares_parse_txt_reply.c.

◆ ares_process()

CARES_EXTERN void ares_process ( ares_channel  channel,
fd_set *  read_fds,
fd_set *  write_fds 
)

Definition at line 134 of file ares_process.c.

◆ ares_process_fd()

CARES_EXTERN void ares_process_fd ( ares_channel  channel,
ares_socket_t  read_fd,
ares_socket_t  write_fd 
)

Definition at line 142 of file ares_process.c.

◆ ares_query()

CARES_EXTERN void ares_query ( ares_channel  channel,
const char *  name,
int  dnsclass,
int  type,
ares_callback  callback,
void *  arg 
)

Definition at line 105 of file ares_query.c.

◆ ares_save_options()

CARES_EXTERN int ares_save_options ( ares_channel  channel,
struct ares_options options,
int optmask 
)

Definition at line 314 of file ares_init.c.

◆ ares_search()

CARES_EXTERN void ares_search ( ares_channel  channel,
const char *  name,
int  dnsclass,
int  type,
ares_callback  callback,
void *  arg 
)

Definition at line 47 of file ares_search.c.

◆ ares_send()

CARES_EXTERN void ares_send ( ares_channel  channel,
const unsigned char *  qbuf,
int  qlen,
ares_callback  callback,
void *  arg 
)

Definition at line 29 of file ares_send.c.

◆ ares_set_local_dev()

CARES_EXTERN void ares_set_local_dev ( ares_channel  channel,
const char *  local_dev_name 
)

Definition at line 2581 of file ares_init.c.

◆ ares_set_local_ip4()

CARES_EXTERN void ares_set_local_ip4 ( ares_channel  channel,
unsigned int  local_ip 
)

Definition at line 2568 of file ares_init.c.

◆ ares_set_local_ip6()

CARES_EXTERN void ares_set_local_ip6 ( ares_channel  channel,
const unsigned char *  local_ip6 
)

Definition at line 2574 of file ares_init.c.

◆ ares_set_servers()

CARES_EXTERN int ares_set_servers ( ares_channel  channel,
struct ares_addr_node servers 
)

Definition at line 143 of file ares_options.c.

◆ ares_set_servers_csv()

CARES_EXTERN int ares_set_servers_csv ( ares_channel  channel,
const char *  servers 
)

Definition at line 395 of file ares_options.c.

◆ ares_set_servers_ports()

CARES_EXTERN int ares_set_servers_ports ( ares_channel  channel,
struct ares_addr_port_node servers 
)

Definition at line 195 of file ares_options.c.

◆ ares_set_servers_ports_csv()

CARES_EXTERN int ares_set_servers_ports_csv ( ares_channel  channel,
const char *  servers 
)

Definition at line 401 of file ares_options.c.

◆ ares_set_socket_callback()

CARES_EXTERN void ares_set_socket_callback ( ares_channel  channel,
ares_sock_create_callback  callback,
void *  user_data 
)

Definition at line 2590 of file ares_init.c.

◆ ares_set_socket_configure_callback()

CARES_EXTERN void ares_set_socket_configure_callback ( ares_channel  channel,
ares_sock_config_callback  callback,
void *  user_data 
)

Definition at line 2598 of file ares_init.c.

◆ ares_set_socket_functions()

CARES_EXTERN void ares_set_socket_functions ( ares_channel  channel,
const struct ares_socket_functions funcs,
void *  user_data 
)

Definition at line 2606 of file ares_init.c.

◆ ares_set_sortlist()

CARES_EXTERN int ares_set_sortlist ( ares_channel  channel,
const char *  sortstr 
)

Definition at line 2614 of file ares_init.c.

◆ ares_strerror()

const CARES_EXTERN char* ares_strerror ( int  code)

Definition at line 21 of file ares_strerror.c.

◆ ares_timeout()

CARES_EXTERN struct timeval* ares_timeout ( ares_channel  channel,
struct timeval maxtv,
struct timeval tv 
)

Definition at line 38 of file ares_timeout.c.

◆ ares_version()

const CARES_EXTERN char* ares_version ( int version)

Definition at line 5 of file ares_version.c.

ARES_AI_PASSIVE
#define ARES_AI_PASSIVE
Definition: ares.h:193
ARES_GETSOCK_MAXNUM
#define ARES_GETSOCK_MAXNUM
Definition: ares.h:209
ARES_AI_CANONNAME
#define ARES_AI_CANONNAME
Definition: ares.h:191
bits
OPENSSL_EXPORT ASN1_BIT_STRING * bits
Definition: x509v3.h:482
ARES_AI_V4MAPPED
#define ARES_AI_V4MAPPED
Definition: ares.h:195
xds_manager.num
num
Definition: xds_manager.py:56
ARES_AI_NUMERICHOST
#define ARES_AI_NUMERICHOST
Definition: ares.h:192
ARES_AI_ALL
#define ARES_AI_ALL
Definition: ares.h:196


grpc
Author(s):
autogenerated on Fri May 16 2025 03:01:03