From 65282c7685ca01c57d94d3df93c2f95d5b945e57 Mon Sep 17 00:00:00 2001 From: "M. Sean Finney" Date: Wed, 19 Oct 2005 12:59:55 +0000 Subject: - initial attempt at consolidating ssl-related code into netutils.{c,h} - added some #ifdefs to common.h and netutils.h to prevent multiple inclusions (as netlibs now includes common.h) - all ssl plugins (tcp/http/smtp) compile cleanly against gnutls, though certificate checking still needs to be done. - modified configure script so you can also explicitly say "without-gnutls" too (otherwise if you disable openssl you have no way of disabling gnutls too) git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1255 f882894a-f735-0410-b71e-b25c423dba1c --- plugins/netutils.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'plugins/netutils.h') diff --git a/plugins/netutils.h b/plugins/netutils.h index 1a52eecc..85b5aa99 100644 --- a/plugins/netutils.h +++ b/plugins/netutils.h @@ -32,7 +32,11 @@ * ******************************************************************************/ +#ifndef _NETUTILS_H_ +#define _NETUTILS_H_ + #include "config.h" +#include "common.h" #include #include @@ -77,3 +81,14 @@ extern unsigned int socket_timeout; extern int econn_refuse_state; extern int was_refused; extern int address_family; + +/* SSL-Related functionality */ +#ifdef HAVE_SSL +/* maybe this could be merged with the above np_net_connect, via some flags */ +int np_net_ssl_init(int sd); +void np_net_ssl_cleanup(); +int np_net_ssl_write(const void *buf, int num); +int np_net_ssl_read(void *buf, int num); +#endif /* HAVE_SSL */ + +#endif /* _NETUTILS_H_ */ -- cgit v1.2.3-74-g34f1