From: Adriaan de Jong Date: Fri, 24 Jun 2011 13:05:28 +0000 (+0200) Subject: Refactored: Added stubs for new files X-Git-Tag: v2.3-alpha1~160 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9a160b796e1a40f9635231e5533ce40d46dba25f;p=thirdparty%2Fopenvpn.git Refactored: Added stubs for new files Signed-off-by: Adriaan de Jong Acked-by: Gert Doering Signed-off-by: David Sommerseth --- diff --git a/Makefile.am b/Makefile.am index ca56ae33c..bdda0be96 100644 --- a/Makefile.am +++ b/Makefile.am @@ -138,7 +138,8 @@ openvpn_SOURCES = \ sig.c sig.h \ socket.c socket.h \ socks.c socks.h \ - ssl.c ssl.h \ + ssl.c ssl.h ssl_backend.h \ + ssl_verify.c ssl_verify.h ssl_verify_backend.h \ status.c status.h \ syshead.h \ tun.c tun.h \ @@ -154,7 +155,9 @@ configure.h: Makefile if USE_OPENSSL openvpn_SOURCES += \ - crypto_openssl.c crypto_openssl.h + crypto_openssl.c crypto_openssl.h \ + ssl_openssl.c ssl_openssl.h \ + ssl_verify_openssl.c ssl_verify_openssl.h endif dist-hook: diff --git a/ssl_backend.h b/ssl_backend.h new file mode 100644 index 000000000..d7e83612e --- /dev/null +++ b/ssl_backend.h @@ -0,0 +1,46 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel SSL library backend module + */ + + +#ifndef SSL_BACKEND_H_ +#define SSL_BACKEND_H_ + +#include "buffer.h" + +#ifdef USE_OPENSSL +#include "ssl_openssl.h" +#endif + + +/* + * + * Functions implemented in ssl.c for use by the backend SSL library + * + */ +#endif /* SSL_BACKEND_H_ */ diff --git a/ssl_common.h b/ssl_common.h new file mode 100644 index 000000000..060e6c67e --- /dev/null +++ b/ssl_common.h @@ -0,0 +1,41 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel Common Data Structures + */ + +#ifndef SSL_COMMON_H_ +#define SSL_COMMON_H_ + +#include "session_id.h" +#include "socket.h" +#include "packet_id.h" +#include "crypto.h" +#include "options.h" + +#include "ssl_backend.h" + +#endif /* SSL_COMMON_H_ */ diff --git a/ssl_openssl.c b/ssl_openssl.c new file mode 100644 index 000000000..b38af8774 --- /dev/null +++ b/ssl_openssl.c @@ -0,0 +1,44 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel OpenSSL Backend + */ + +#include "syshead.h" +#include "errlevel.h" +#include "buffer.h" +#include "misc.h" +#include "manage.h" +#include "memdbg.h" +#include "ssl_backend.h" +#include "ssl_common.h" + +#include "ssl_verify_openssl.h" + +#include +#include +#include +#include diff --git a/ssl_openssl.h b/ssl_openssl.h new file mode 100644 index 000000000..d412ef230 --- /dev/null +++ b/ssl_openssl.h @@ -0,0 +1,35 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel OpenSSL Backend + */ + +#ifndef SSL_OPENSSL_H_ +#define SSL_OPENSSL_H_ + +#include + +#endif /* SSL_OPENSSL_H_ */ diff --git a/ssl_verify.c b/ssl_verify.c new file mode 100644 index 000000000..df22b5920 --- /dev/null +++ b/ssl_verify.c @@ -0,0 +1,38 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel Verification Module + */ + +#include "syshead.h" +#include "misc.h" +#include "manage.h" +#include "ssl_verify.h" +#include "ssl_verify_backend.h" + +#ifdef USE_OPENSSL +#include "ssl_verify_openssl.h" +#endif diff --git a/ssl_verify.h b/ssl_verify.h new file mode 100644 index 000000000..19e0bdc77 --- /dev/null +++ b/ssl_verify.h @@ -0,0 +1,44 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel Verification Module + */ + +#ifndef SSL_VERIFY_H_ +#define SSL_VERIFY_H_ + +#include "syshead.h" +#include "misc.h" +#include "manage.h" +#include "ssl_common.h" + +/* Include OpenSSL-specific code */ +#ifdef USE_OPENSSL +#include "ssl_verify_openssl.h" +#endif + + +#endif /* SSL_VERIFY_H_ */ diff --git a/ssl_verify_backend.h b/ssl_verify_backend.h new file mode 100644 index 000000000..9dbfd7f43 --- /dev/null +++ b/ssl_verify_backend.h @@ -0,0 +1,33 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel Verification Module library-specific backend interface + */ + +#ifndef SSL_VERIFY_BACKEND_H_ +#define SSL_VERIFY_BACKEND_H_ + +#endif /* SSL_VERIFY_BACKEND_H_ */ diff --git a/ssl_verify_openssl.c b/ssl_verify_openssl.c new file mode 100644 index 000000000..a654e3d63 --- /dev/null +++ b/ssl_verify_openssl.c @@ -0,0 +1,33 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel Verification Module OpenSSL implementation + */ + +#include "ssl_verify.h" +#include "ssl_verify_backend.h" +#include "ssl_openssl.h" +#include diff --git a/ssl_verify_openssl.h b/ssl_verify_openssl.h new file mode 100644 index 000000000..e48f1096e --- /dev/null +++ b/ssl_verify_openssl.h @@ -0,0 +1,35 @@ +/* + * OpenVPN -- An application to securely tunnel IP networks + * over a single TCP/UDP port, with support for SSL/TLS-based + * session authentication and key exchange, + * packet encryption, packet authentication, and + * packet compression. + * + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. + * Copyright (C) 2010 Fox Crypto B.V. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program (see the file COPYING included with this + * distribution); if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/** + * @file Control Channel Verification Module OpenSSL backend + */ + + +#ifndef SSL_VERIFY_OPENSSL_H_ +#define SSL_VERIFY_OPENSSL_H_ + +#include +#endif /* SSL_VERIFY_OPENSSL_H_ */