#include <gnunet_private_config.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <assert.h>
#include <netdb.h>
#include <sys/socket.h>
#include <nss.h>
#include <stdio.h>
#include <stdlib.h>
#include "nss_gns_query.h"
#include <arpa/inet.h>
Go to the source code of this file.
Macros | |
#define | ALIGN(idx) |
macro to align idx to 32bit boundary More... | |
Functions | |
enum nss_status | _nss_gns_gethostbyname2_r (const char *name, int af, struct hostent *result, char *buffer, size_t buflen, int *errnop, int *h_errnop) |
The gethostbyname hook executed by nsswitch. More... | |
enum nss_status | _nss_gns_gethostbyname_r (const char *name, struct hostent *result, char *buffer, size_t buflen, int *errnop, int *h_errnop) |
The gethostbyname hook executed by nsswitch. More... | |
enum nss_status | _nss_gns_gethostbyaddr_r (const void *addr, int len, int af, struct hostent *result, char *buffer, size_t buflen, int *errnop, int *h_errnop) |
The gethostbyaddr hook executed by nsswitch We can't do this so we always return NSS_STATUS_UNAVAIL. More... | |
#define ALIGN | ( | idx | ) |
enum nss_status _nss_gns_gethostbyname2_r | ( | const char * | name, |
int | af, | ||
struct hostent * | result, | ||
char * | buffer, | ||
size_t | buflen, | ||
int * | errnop, | ||
int * | h_errnop | ||
) |
The gethostbyname hook executed by nsswitch.
name | the name to resolve |
af | the address family to resolve |
result | the result hostent |
buffer | the result buffer |
buflen | length of the buffer |
errnop | idk |
h_errnop | idk |
Definition at line 66 of file nss_gns.c.
References ALIGN, gns_resolve_name(), name, result, status, and u.
Referenced by _nss_gns_gethostbyname_r().
enum nss_status _nss_gns_gethostbyname_r | ( | const char * | name, |
struct hostent * | result, | ||
char * | buffer, | ||
size_t | buflen, | ||
int * | errnop, | ||
int * | h_errnop | ||
) |
The gethostbyname hook executed by nsswitch.
name | the name to resolve | |
result | the result hostent | |
buffer | the result buffer | |
buflen | length of the buffer | |
[out] | errnop | the low-level error code to return to the application |
h_errnop | idk |
Definition at line 215 of file nss_gns.c.
References _nss_gns_gethostbyname2_r(), name, and result.
enum nss_status _nss_gns_gethostbyaddr_r | ( | const void * | addr, |
int | len, | ||
int | af, | ||
struct hostent * | result, | ||
char * | buffer, | ||
size_t | buflen, | ||
int * | errnop, | ||
int * | h_errnop | ||
) |
The gethostbyaddr hook executed by nsswitch We can't do this so we always return NSS_STATUS_UNAVAIL.
addr | the address to resolve | |
len | the length of the address | |
af | the address family of the address | |
result | the result hostent | |
buffer | the result buffer | |
buflen | length of the buffer | |
[out] | errnop | the low-level error code to return to the application |
h_errnop | idk |
Definition at line 255 of file nss_gns.c.
References result.