syslog-ng source
host-resolve.c File Reference
#include "host-resolve.h"
#include "hostname.h"
#include "dnscache.h"
#include "messages.h"
#include "cfg.h"
#include "tls-support.h"
#include "compat/socket.h"
#include "apphook.h"
#include <iv.h>
#include <arpa/inet.h>
#include <netdb.h>
#include <string.h>
#include <resolv.h>
Include dependency graph for host-resolve.c:

Macros

#define AI_V4MAPPED   0
 
#define hostname_buffer   __slng_tls_deref(hostname_buffer)
 

Functions

 G_LOCK_DEFINE_STATIC (resolv_lock)
 
gboolean resolve_hostname_to_sockaddr (GSockAddr **addr, gint family, const gchar *name)
 
const gchar * resolve_sockaddr_to_hostname (gsize *result_len, GSockAddr *saddr, const HostResolveOptions *host_resolve_options)
 
const gchar * resolve_hostname_to_hostname (gsize *result_len, const gchar *hname, HostResolveOptions *host_resolve_options)
 
void host_resolve_options_defaults (HostResolveOptions *options)
 
void host_resolve_options_global_defaults (HostResolveOptions *options)
 
void host_resolve_options_init_globals (HostResolveOptions *options)
 
void host_resolve_options_init (HostResolveOptions *options, HostResolveOptions *global_options)
 
void host_resolve_options_destroy (HostResolveOptions *options)
 
void host_resolve_global_init (void)
 

Variables

 TLS_BLOCK_START
 
 TLS_BLOCK_END
 

Macro Definition Documentation

◆ AI_V4MAPPED

#define AI_V4MAPPED   0

◆ hostname_buffer

#define hostname_buffer   __slng_tls_deref(hostname_buffer)

Function Documentation

◆ G_LOCK_DEFINE_STATIC()

G_LOCK_DEFINE_STATIC ( resolv_lock  )

◆ host_resolve_global_init()

void host_resolve_global_init ( void  )

◆ host_resolve_options_defaults()

void host_resolve_options_defaults ( HostResolveOptions options)

◆ host_resolve_options_destroy()

void host_resolve_options_destroy ( HostResolveOptions options)

◆ host_resolve_options_global_defaults()

void host_resolve_options_global_defaults ( HostResolveOptions options)

◆ host_resolve_options_init()

void host_resolve_options_init ( HostResolveOptions options,
HostResolveOptions global_options 
)

◆ host_resolve_options_init_globals()

void host_resolve_options_init_globals ( HostResolveOptions options)

◆ resolve_hostname_to_hostname()

const gchar* resolve_hostname_to_hostname ( gsize *  result_len,
const gchar *  hname,
HostResolveOptions host_resolve_options 
)

◆ resolve_hostname_to_sockaddr()

gboolean resolve_hostname_to_sockaddr ( GSockAddr **  addr,
gint  family,
const gchar *  name 
)

◆ resolve_sockaddr_to_hostname()

const gchar* resolve_sockaddr_to_hostname ( gsize *  result_len,
GSockAddr saddr,
const HostResolveOptions host_resolve_options 
)

Variable Documentation

◆ TLS_BLOCK_END

TLS_BLOCK_END

◆ TLS_BLOCK_START

TLS_BLOCK_START
Initial value:
{
gchar hostname_buffer[256]
#define hostname_buffer
Definition: host-resolve.c:53