0
0
mirror of https://github.com/OpenVPN/openvpn.git synced 2024-09-20 03:52:28 +02:00
Commit Graph

47 Commits

Author SHA1 Message Date
Gert Doering
ed77e8ad8e log error message and exit for "win32, tun mode, tap driver version 9.8"
(driver is known-buggy for small IPv4 packets in tun mode)

Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
(cherry-picked from commit 03ab4ead82)
2011-11-23 16:10:21 +01:00
David Sommerseth
22c7d4699b Remove support for Linux 2.2 configuration fallback
When configuring OpenVPN nowadays, the TUN/TAP configuration can
sometimes jump into the Linux 2.2 fallback code paths, which will
also fails.  The reason it jumps into fallback mode is that the
tun/tap device already exists or that /dev/net/tun does not exist.
This can be very confusing, as /dev/tunX which the fallback mode tries
to use, does not exist on Linux 2.4 and newer.

Considering that the last Linux 2.2 update was released 25-Feb-2004
and the first Linux 2.4 release came 04-Jan-2001, there are no
reasonable reasons to help users to stay on outdated kernels.
I consider this extra code path just waste of bytes ... so lets make
the world simpler.

Signed-off-by: David Sommerseth <davids@redhat.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
(cherry picked from commit ce637abdaf)
2011-06-15 12:00:57 +02:00
James Yonan
bc454059ce Minor addition of logging info before and after
execution of Windows net commands.

Version 2.1.3d

git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@6712 e7ae566f-a301-0410-adde-c780ea21d3b5

Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
(cherry picked from commit 7621741b48)
2010-12-20 13:36:03 +01:00
David Sommerseth
1aa664cef5 Merge branch 'feat_misc' into beta2.2
Conflicts:
	Makefile.am
	openvpn.8
	options.c
	socket.c
	ssl.c
	- feat_misc is missing a lot of bugfix2.1 changes

Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
2010-11-13 00:55:02 +01:00
Gert Doering
f0eac1a597 Make "topology subnet" work on Solaris (ifconfig + route metric changes by Kazuyoshi Aizawa, adding of local "connected subnet" route by me)
Tested on OpenSolaris/i386, no impact for other TARGETs.

Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Kazuyoshi Aizawa <admin2@whiteboard.ne.jp>
Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
2010-11-12 21:54:08 +01:00
Gert Doering
121755c2cb Integrate support for TAP mode on Solaris, written by Kazuyoshi Aizawa <admin2@whiteboard.ne.jp>.
See also http://www.whiteboard.ne.jp/~admin2/tuntap/

Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Kazuyoshi Aizawa <admin2@whiteboard.ne.jp>
Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
2010-11-12 21:54:03 +01:00
Gert Doering
8528e2b77d remove duplicate code in FREEBSD+DRAGONFLY system-dependent ifconfig
(ACKed by Eric F Crist and David Sommerseth)

(cherry picked from commit dd66b12647852e3f1267be70b0fb3b11deedf377)

Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
Signed-off-by: Gert Doering <gert@greenie.muc.de>
2010-10-21 11:33:42 +02:00
James Yonan
1d76ecbcd0 Don't configure Linux tun/tap txqueuelen setting if OpenVPN
txqueuelen directive is set to 0.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@6420 e7ae566f-a301-0410-adde-c780ea21d3b5
2010-08-31 21:39:30 +00:00
James Yonan
75dfe3d7f7 Added "net stop dnscache" and "net start dnscache" in front
of existing --register-dns commands.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@6352 e7ae566f-a301-0410-adde-c780ea21d3b5
2010-07-27 21:46:34 +00:00
James Yonan
b90c6f17b4 Added --register-dns option for Windows.
Fixed some issues on Windows with --log, subprocess creation
for command execution, and stdout/stderr redirection.

Version 2.1.1m.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@6304 e7ae566f-a301-0410-adde-c780ea21d3b5
2010-07-16 18:01:11 +00:00
James Yonan
564a21094e Updated copyright date to 2010.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@5599 e7ae566f-a301-0410-adde-c780ea21d3b5
2010-04-28 16:31:36 +00:00
James Yonan
74fce85ee8 Updated MSVC build scripts to Visual Studio 2008:
python msvc\config.py
  nmake /f msvc\msvc.mak

Version 2.1.1e


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@5516 e7ae566f-a301-0410-adde-c780ea21d3b5
2010-03-31 06:38:21 +00:00
Gert Doering
1ed4098663 remove duplicate code in FREEBSD+DRAGONFLY system-dependent ifconfig
(ACKed by Eric F Crist and David Sommerseth)

(cherry picked from commit dd66b12647852e3f1267be70b0fb3b11deedf377)

Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
Signed-off-by: Gert Doering <gert@greenie.muc.de>
2010-02-28 23:42:12 +01:00
james
5c30df12ae Fixed a client-side bug that occurred when the "dhcp-pre-release"
or "dhcp-renew" options were combined with "route-gateway dhcp".

The problem is that the IP Helper functions for DHCP release and
renew are blocking, and so calling them from a single-threaded
client stops tunnel traffic forwarding, and hence breaks
"route-gateway dhcp" which requires an active tunnel.  The fix is
to call the IP Helper functions for DHCP release and renew from
another process.

Version 2.1_rc21b.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@5164 e7ae566f-a301-0410-adde-c780ea21d3b5
2009-11-19 16:42:51 +00:00
james
b69d5cc8f5 Fixed ifconfig command for "topology subnet" on FreeBSD (Stefan Bethke).
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@4837 e7ae566f-a301-0410-adde-c780ea21d3b5
2009-08-19 15:55:14 +00:00
james
d7fa38f2a9 Update copyright to 2009.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@4477 e7ae566f-a301-0410-adde-c780ea21d3b5
2009-05-30 21:38:49 +00:00
james
a828135275 * Added additional method parameter to --script-security to preserve
backward compatibility with system() call semantics used in OpenVPN
  2.1_rc8 and earlier.  To preserve backward compatibility use:

    script-security 3 system


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3495 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-11-17 04:28:07 +00:00
james
367ed084db Copyright notice changed to reflect change in name of
Telethra to OpenVPN Technologies.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3409 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-10-06 07:33:45 +00:00
james
f77c60d3d6 Added additional warnings to flag common gotchas:
* Warn when ethernet bridging that the IP address of the
  bridge adapter is probably not the same address that
  the LAN adapter was set to previously.

* When running as a server, warn if the LAN network address is
  the all-popular 192.168.[0|1].x, since this condition commonly
  leads to subnet conflicts down the road.

* Primarily on the client, check for subnet conflicts between
  the local LAN and the VPN subnet.

Added a 'netmask' parameter to get_default_gateway, to return
the netmask of the adapter containing the default gateway.
Only implemented on Windows so far.  Other platforms will
return 255.255.255.0.  Currently the netmask information is
only used to warn about subnet conflicts.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3179 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-08-05 04:44:31 +00:00
james
b4073a7602 Perform additional input validation on options pulled
by client from server.  Fixes --iproute vulnerability.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3126 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-07-26 23:08:29 +00:00
james
5a2e9a2587 Completely revamped the system for calling external programs and scripts:
* All external programs and scripts are now called by execve() on unix and
  CreateProcess on Windows.

* The system() function is no longer used.

* Argument lists for external programs and scripts are now built by the new
  argv_printf function which natively outputs to string arrays (i.e.
  char *argv[] lists), never truncates its output, and eliminates the security
  issues inherent in formatting and parsing command lines, and dealing with
  argument quoting.

* The --script-security directive has been added to offer policy controls on
  OpenVPN's execution of external programs and scripts.

Also added a new plugin example (openvpn/plugin/examples/log.c) that logs
information to stdout for every plugin method called by OpenVPN.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3122 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-07-26 07:27:03 +00:00
james
cc1d3998d2 Reverted some recent buffer.[ch] changes, including r3058 (except for
likely() and unlikely() macro additions to syshead.h) and r3061.

I would like to give more thought to the bigger issue of fortifying
buffer.[ch] through the use of additional defensive programming techniques.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3081 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-07-18 20:46:06 +00:00
james
4fb01ce0ba In the Windows version of tun_finalize, on errors that would
return -1, set buf->len to 0 rather than -1.  While downstream
code is set up to consider the buffer invalidated if its length
is <= 0, this change makes the code cleaner and safer.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3061 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-07-16 22:37:09 +00:00
james
1c0cc4ad89 Copyright change OpenVPN Solutions LLC -> Telethra, Inc.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@3048 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-07-14 18:59:09 +00:00
james
eca86913db Updated copyright notice to 2008.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2995 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-06-11 21:59:26 +00:00
james
90efcacba6 Updated version to 2.1_rc7e.
Added client authentication and packet filtering capability
to management interface.

Extended packet filtering capability to work on both --dev tun
and --dev tap tunnels.

Updated valgrind-suppress file.

Made "Linux ip addr del failed" error nonfatal.

Amplified --client-cert-not-required warning.

Added #pragma pack to proto.h.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2991 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-06-11 08:45:09 +00:00
james
1bda73a7b0 Moved branch into official BETA21 position.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2959 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-05-12 20:31:43 +00:00
james
252a728256 Cleanup IP address for persistence interfaces for tap and also using
ifconfig, gentoo#209055 (Alon Bar-Lev).


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2748 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-02-17 07:05:49 +00:00
james
4fa5b75834 Fixup null interface on close, don't use ip addr flush
(Alon Bar-Lev).


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2683 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-01-26 04:43:13 +00:00
james
5aa3cfaf68 Changed ASSERT(0) to a more descriptive fatal error in tun.c
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2641 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-01-21 19:59:58 +00:00
james
0aee9ca7e7 Allow OpenVPN to run completely unprivileged under Linux
by allowing openvpn --mktun to be used with --user and --group
to set the UID/GID of the tun device node.  Also added --iproute
option to allow an alternative command to be executed in place
of the default iproute2 command (Alon Bar-Lev).


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@2639 e7ae566f-a301-0410-adde-c780ea21d3b5
2008-01-21 19:34:13 +00:00
james
657ecf14ac TAP driver now passes signing tests on Vista x64.
Added new settings to settings.in to better control
build process.

Removed some unneeded JYFIXMEs from source code.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1874 e7ae566f-a301-0410-adde-c780ea21d3b5
2007-04-25 21:37:49 +00:00
james
5f31881ec1 New try at AUTO_USERID.
Implemented AUTO_USERID using
MD5(MAC address(primary network adapter)).
Currently implemented for Linux and Windows.

Basically if ENABLE_AUTO_USERID is defined,
the --auth-user-pass option will not prompt
for username/password, but will rather generate
a unique username and blank password.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1459 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-11-13 09:44:10 +00:00
james
1f99578ce9 Backed out AUTO_USERID feature introduced in r1436.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1449 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-11-10 10:22:48 +00:00
james
004d8b48a8 Fixed issue where OpenVPN does not apply the --txqueuelen option
to persistent interfaces made with --mktun (Roy Marples).


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1447 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-11-09 09:49:14 +00:00
james
2270775d8c Added #ifdefed out AUTO_USERID feature.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1436 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-11-08 04:02:56 +00:00
james
d1270d07b2 TAP-Win32 fixes to run on Windows Vista.
Modified installer to detect 32-bit vs.
64 bit Windows and install the correct TAP
driver.

TAP-Win32 version number is at 8.4.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1229 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-09-14 02:18:40 +00:00
james
adff31cc32 Comment about assertion being hit.
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1079 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-07-03 19:54:17 +00:00
james
dcc0b2447e Eliminated gcc 3.3.3 warnings on NetBSD
when ./configure --enable-strict is used.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1040 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-06-24 08:04:42 +00:00
james
55ff44b4ef svn merge -r 886:987 $SO/trunk/openvpn .
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@991 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-04-05 07:30:04 +00:00
james
c1c27fe32a "topology subnet" fix for FreeBSD (Benoit Bourdin).
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@986 e7ae566f-a301-0410-adde-c780ea21d3b5
2006-04-05 06:28:19 +00:00
james
a9c802b2a3 --ip-win32 adaptive is now the default.
--ip-win32 netsh (or --ip-win32 adaptive when in netsh
mode) can now set DNS/WINS addresses on the TAP-Win32
adapter.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@857 e7ae566f-a301-0410-adde-c780ea21d3b5
2005-12-22 18:09:40 +00:00
james
6d5d1010bc Patch to support --topology subnet on Mac OS X (Mathias Sundman).
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@832 e7ae566f-a301-0410-adde-c780ea21d3b5
2005-12-05 01:21:49 +00:00
james
c67d59cd5c Windows reliability changes:
* Added code to make sure that the local PATH environmental
variable points to the Windows system32 directory.
* Added new --ip-win32 adaptive mode which tries 'dynamic'
and then fails over to 'netsh' if the DHCP negotiation fails.
* Made --ip-win32 adaptive the default.


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@739 e7ae566f-a301-0410-adde-c780ea21d3b5
2005-10-31 03:01:17 +00:00
james
5ad84585de Added actual remote address used to the ">STATE" alert
in the management interface (Rolf Fokkens).


git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@701 e7ae566f-a301-0410-adde-c780ea21d3b5
2005-10-20 19:00:56 +00:00
james
3c7f2f553b version 2.1_beta1
git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@581 e7ae566f-a301-0410-adde-c780ea21d3b5
2005-09-26 07:40:02 +00:00
james
6fbf66fad3 This is the start of the BETA21 branch.
It includes the --topology feature, and
TAP-Win32 driver changes to allow
non-admin access.



git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@580 e7ae566f-a301-0410-adde-c780ea21d3b5
2005-09-26 05:28:27 +00:00