summaryrefslogtreecommitdiffstats
path: root/plugins/netutils.h
diff options
context:
space:
mode:
authorHolger Weiss <holger@zedat.fu-berlin.de>2016-11-17 16:22:37 (GMT)
committerHolger Weiss <holger@zedat.fu-berlin.de>2016-11-17 16:22:37 (GMT)
commit487a9d0a8b0700c06857d4bc35423db4e4dbc3d6 (patch)
treeabfdc545a658550e32a69f0dfdd8ace3aa9f5a41 /plugins/netutils.h
parentbfc745a79d4912479b725c00375aa171f8528ca2 (diff)
downloadmonitoring-plugins-487a9d0.tar.gz
check_radius: Replace functions removed in radcli
The radcli library no longer offers the rc_get_ipaddr(), rc_good_ipaddr(), and rc_own_ipaddress() functions.
Diffstat (limited to 'plugins/netutils.h')
-rw-r--r--plugins/netutils.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/netutils.h b/plugins/netutils.h
index 2766029..d7ee0dd 100644
--- a/plugins/netutils.h
+++ b/plugins/netutils.h
@@ -45,6 +45,10 @@
45# endif /* UNIX_PATH_MAX */ 45# endif /* UNIX_PATH_MAX */
46#endif /* HAVE_SYS_UN_H */ 46#endif /* HAVE_SYS_UN_H */
47 47
48#ifndef HOST_MAX_BYTES
49# define HOST_MAX_BYTES 255
50#endif
51
48/* process_request and wrapper macros */ 52/* process_request and wrapper macros */
49#define process_tcp_request(addr, port, sbuf, rbuf, rsize) \ 53#define process_tcp_request(addr, port, sbuf, rbuf, rsize) \
50 process_request(addr, port, IPPROTO_TCP, sbuf, rbuf, rsize) 54 process_request(addr, port, IPPROTO_TCP, sbuf, rbuf, rsize)
@@ -71,8 +75,9 @@ int send_request (int sd, int proto, const char *send_buffer, char *recv_buffer,
71/* "is_*" wrapper macros and functions */ 75/* "is_*" wrapper macros and functions */
72int is_host (const char *); 76int is_host (const char *);
73int is_addr (const char *); 77int is_addr (const char *);
74int resolve_host_or_addr (const char *, int); 78int dns_lookup (const char *, struct sockaddr_storage *, int);
75void host_or_die(const char *str); 79void host_or_die(const char *str);
80#define resolve_host_or_addr(addr, family) dns_lookup(addr, NULL, family)
76#define is_inet_addr(addr) resolve_host_or_addr(addr, AF_INET) 81#define is_inet_addr(addr) resolve_host_or_addr(addr, AF_INET)
77#ifdef USE_IPV6 82#ifdef USE_IPV6
78# define is_inet6_addr(addr) resolve_host_or_addr(addr, AF_INET6) 83# define is_inet6_addr(addr) resolve_host_or_addr(addr, AF_INET6)