]> git.ipfire.org Git - thirdparty/openvpn.git/log
thirdparty/openvpn.git
13 years agoSome filesystems don't like ':', which is a path 'make dist' would use
David Sommerseth [Fri, 4 May 2012 14:37:00 +0000 (16:37 +0200)] 
Some filesystems don't like ':', which is a path 'make dist' would use

In commit 7a845401043dbd9c the version.m4 was modified to remove the
alpha1 tag.  But then Alon Bar-Lev noticed that NTFS wasn't happy about
the ':' character.  So let's rather just skip the complete 'git:'
prefix and use just 'master' instead.

Reported-by: Alon Bar-Lev <alon.barlev@gmail.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoChange version to indicate the master branch is not a version
David Sommerseth [Tue, 21 Feb 2012 14:11:38 +0000 (15:11 +0100)] 
Change version to indicate the master branch is not a version

This also indicates that we're way past the released 2.3-alpha1

Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoSimplify check_cmd_access() function
David Sommerseth [Wed, 2 May 2012 17:54:12 +0000 (19:54 +0200)] 
Simplify check_cmd_access() function

To avoid confusion between check_file_access() and check_cmd_access() in
the future, remove unneeded arguments from check_cmd_access()

As a command will always be a file, it should always check for CHKACC_FILE
and nothing else.  And as the commands always will need X_OK, check only
for that.

One change from earlier behaviour is that R_OK is not checked for.  The
reason is that only scripts require R_OK to work.  However, a system might
be installed with binaries with only X_OK set.  If a script is missing
R_OK, then the execution will fail due to lacking permissions.

Signed-off-by: David Sommerseth <davids@redhat.com>
Acked-by: Alon Bar-Lev <alon.barlev@gmail.com>
Message-Id: 1335981252-7390-1-git-send-email-davids@redhat.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6391

13 years agobuild: windows: convert resources to UTF-8
Alon Bar-Lev [Sat, 28 Apr 2012 18:29:01 +0000 (21:29 +0300)] 
build: windows: convert resources to UTF-8

Visual Studio 2010 editor supports UTF-8 files, we can store files in
standard encoding.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Message-Id: 1335637741-15721-1-git-send-email-alon.barlev@gmail.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6380
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoClarified the docs and help screen about what a 'cmd' is
Jonathan K. Bullard [Sat, 31 Mar 2012 11:47:34 +0000 (07:47 -0400)] 
Clarified the docs and help screen about what a 'cmd' is

This also changes the descriptions of several options to note that they accept
a "command"; change the description of --client-connect and --client-disconnect
indicate that the temporary file's path is passed as the last argument to the
command, not the first argument; and Adds a description of --route-pre-down to
the descriptions of the other --route options.

[DS: This patch is based on parts of the options.c.diff and the complete
     openvpn.8.diff patch sent to the mailing list - where these docs changes
     are merged together into this patch]

Signed-off-by: Jonathan K. Bullard <jkbullard@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: CAEsd45RkyJw6yUk1Jwkip70HkCjKYoU+V=do3N7SH7JOaHBZdw@mail.gmail.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6194
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoFix file access checks on commands
Jonathan K. Bullard [Sat, 31 Mar 2012 11:47:34 +0000 (07:47 -0400)] 
Fix file access checks on commands

The current implementation of check_file_access() does not consider that
some options take scripts and executables as input.  When some of these
commands are given arguments in the OpenVPN configuration,
check_file_access() would take those arguments as a part of the file name
to the command.  Thus the file check would fail.

This patch improves that by introducing a check_cmd_access() function which
first splits out the arguments to the command before checking if the file
with the command is available.

[DS: This patch is splitted out from the options.c.diff patch sent to the
     mailing list - where only the function changes is included here]

Signed-off-by: Jonathan K. Bullard <jkbullard@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: CAEsd45RkyJw6yUk1Jwkip70HkCjKYoU+V=do3N7SH7JOaHBZdw@mail.gmail.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6194
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRemoved stray "Fox-IT hardening" string.
Adriaan de Jong [Mon, 2 Apr 2012 07:28:06 +0000 (09:28 +0200)] 
Removed stray "Fox-IT hardening" string.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Message-Id: 1333351687-3732-5-git-send-email-dejong@fox-it.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6212
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: fix typo in --enable-save-password
Alon Bar-Lev [Fri, 27 Apr 2012 13:40:54 +0000 (16:40 +0300)] 
build: fix typo in --enable-save-password

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Message-Id: 1335534054-14895-1-git-send-email-alon.barlev@gmail.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6371
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: use stdbool.h if available
Alon Bar-Lev [Fri, 27 Apr 2012 12:09:15 +0000 (15:09 +0300)] 
build: use stdbool.h if available

If stdbool.h is available use it, otherwise create emulation.

basic.h defines a type 'bool' that conflicts with
the altivec keyword bool which has to be fixed upstream, see
bugs[1][2].

[1] https://bugs.gentoo.org/show_bug.cgi?id=293840
[2] https://bugs.gentoo.org/show_bug.cgi?id=297854

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Message-Id: 1335528555-13225-1-git-send-email-alon.barlev@gmail.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6363
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoUpdated README.polarssl with build system changes.
Adriaan de Jong [Mon, 2 Apr 2012 07:28:07 +0000 (09:28 +0200)] 
Updated README.polarssl with build system changes.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Message-Id: 1333351687-3732-6-git-send-email-dejong@fox-it.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6209
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRemoved support for PolarSSL < 1.1
Adriaan de Jong [Mon, 2 Apr 2012 07:28:05 +0000 (09:28 +0200)] 
Removed support for PolarSSL < 1.1

PolarSSL 1.0 and earlier use only the Havege RNG. Havege is based on timing
certain operations, using the RDTSC instruction. Although this is fine on
bare metal PCs, the RDTSC instruction is virtualised on some virtual
machine implementations. This can result in issues on those virtual
machines. PolarSSL fixes this potential issue by also using platform
entropy.

To ensure that OpenVPN is always built against a decent RNG, PolarSSL <1.1
is therefore no longer supported.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Message-Id: 1333351687-3732-4-git-send-email-dejong@fox-it.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6211
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoUse POLARSSL_CFLAGS instead of POLARSSL_CRYPTO_CFLAGS in configure.ac
Adriaan de Jong [Mon, 2 Apr 2012 07:28:04 +0000 (09:28 +0200)] 
Use POLARSSL_CFLAGS instead of POLARSSL_CRYPTO_CFLAGS in configure.ac

Ensured that the used variable name actually matches the one advertised by configure.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: Alon Bar-Lev <alon.barlev@gmail.com>
Message-Id: 1333351687-3732-3-git-send-email-dejong@fox-it.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6208
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoAdded a configuration option to enable prediction resistance in the PolarSSL random...
Adriaan de Jong [Mon, 2 Apr 2012 07:28:03 +0000 (09:28 +0200)] 
Added a configuration option to enable prediction resistance in the PolarSSL random number generator.

Signed-off-by: Eelse-jan Stutvoet <stutvoet@fox-it.com>
Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: James Yonan <james@openvpn.net>
Message-Id: 1333351687-3732-2-git-send-email-dejong@fox-it.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6213
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoAdded support for new PolarSSL 1.1 RNG
Adriaan de Jong [Mon, 2 Apr 2012 07:28:02 +0000 (09:28 +0200)] 
Added support for new PolarSSL 1.1 RNG

This patch, while retaining PolarSSL 1.0 support, introduces the PolarSSL 1.1 DRBG.
This RNG adds a number of features, including support for personalisation strings
and multiple entropy sources.

Personalisation strings have been implemented, based on PID, program name, place
within memory, and a hash of the user's certificate.

The entropy sources used are the platform default ones. Which ones these are
depends on how PolarSSL was built, but usually this includes:

 - /dev/urandom or the Windows CryptoAPI RNG
 - the HAVEGE RNG
 - the output of PolarSSL's hardclock() call (usually RDTSC)

Finally, this patch moves to only one instance of the RNG  per OpenVPN instance,
instead of one per keystate

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Signed-off-by: Eelse-jan Stutvoet <stutvoet@fox-it.com>
Acked-by: James Yonan <james@openvpn.net>
Message-Id: 1333351687-3732-1-git-send-email-dejong@fox-it.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6210
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocrash: packet_id_debug_print: sl may be null
Alon Bar-Lev [Sun, 8 Apr 2012 10:04:45 +0000 (13:04 +0300)] 
crash: packet_id_debug_print: sl may be null

Program received signal SIGSEGV, Segmentation fault.
packet_id_debug_print (msglevel=1174405255, p=0xa36bd0718,
pin=0x3de5feec1b0,
message=0xa330dde80 "PID_TEST", value=0) at
../../../src/openvpn/packet_id.c:504
504       for (i = 0; i < sl->x_size; ++i)

(gdb) print sl
$2 = (const struct seq_list *) 0x0

Reported in the past[1].

[1] http://thread.gmane.org/gmane.network.openvpn.devel/5466

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: James Yonan <james@openvpn.net>
Message-Id: 1333879485-2417-1-git-send-email-alon.barlev@gmail.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6259
Message-Id: 4F9A6B4B.7060502@openvpn.net
URL: http://article.gmane.org/gmane.network.openvpn.devel/6350
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoClean-up: Presume that Linux is always IPv6 capable at build time
David Sommerseth [Fri, 27 Apr 2012 10:10:25 +0000 (12:10 +0200)] 
Clean-up: Presume that Linux is always IPv6 capable at build time

These days it is highly unlikely that OpenVPN will be built in a non-IPv6
capable Linux environment.  So remove compile-time related macros identifying
that.

This also solves an issue which was introduced in commit 51bd56f46f55177cf0f8b
where HAVE_TUN_PI is no longer detected.  The tun_pi struct is defined in
linux/if_tun.h, which will be checked for later on.  As this struct has history
in linux/if_tun.h all back to the beginning of the kernel git tree (2.6.12-rc2,
April 2005), it is considered not needed to check for this struct explicit.

[ v2: Commit 7c0a2b5f2b4409 modifies some of the checks this patch touches.  This
      patch just adopts to those changes ]

Signed-off-by: David Sommerseth <davids@redhat.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Alon Bar-Lev <alon.barlev@gmail.com>
Message-Id: 1335521425-23391-1-git-send-email-davids@redhat.com
URL: http://article.gmane.org/gmane.network.openvpn.devel/6351

13 years agocleanup: add .gitattributes to control eol style explicitly
Alon Bar-Lev [Mon, 2 Apr 2012 11:37:41 +0000 (14:37 +0300)] 
cleanup: add .gitattributes to control eol style explicitly

Having the text auto detection is a risk, as the detection may detect
text files that are not text and vise versa.

Having global setting will create confusion and differentiate between
users. So this patch also move this to local repository.

Having git to check out files differently in different OS is also
a not correct, as checkouts may be used in shares or in *NIX emulation
environments, so it have no effect.

Another issue is packaging, if we change out the tree differently
in several OSes, we may have different package content, which is
something that should be avoided.

Currently any editor of MS supports LF end of lines, so there is no
need to convert source files while checking out.

The visual studio files should be stored as CRLF as they are generated
by visual studio every save, in a way that CRLF are added.

I handled only the files that may be touch by MS users.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Fabian Knittel <fabian.knittel@lettink.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoEnsure sys/un.h autoconf detection includes sys/socket.h
Adriaan de Jong [Thu, 12 Apr 2012 06:50:12 +0000 (08:50 +0200)] 
Ensure sys/un.h autoconf detection includes sys/socket.h

This is required to build an Android binary.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: Alon Bar-Lev <alon.barlev@gmail.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: remove C++ comments
Alon Bar-Lev [Sat, 7 Apr 2012 17:42:27 +0000 (20:42 +0300)] 
cleanup: remove C++ comments

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Fabian Knittel <fabian.knittel@lettink.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: plugin: support C++ plugin
Alon Bar-Lev [Sat, 7 Apr 2012 17:40:40 +0000 (20:40 +0300)] 
cleanup: plugin: support C++ plugin

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Fabian Knittel <fabian.knittel@lettink.de>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: properly detect TUNSETPERSIST
Alon Bar-Lev [Sun, 8 Apr 2012 19:21:47 +0000 (22:21 +0300)] 
build: properly detect TUNSETPERSIST

Do not rely on system symbol throught sources
but on autoconf detection.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: properly detect netinet/ip.h structs
Alon Bar-Lev [Sun, 8 Apr 2012 19:22:09 +0000 (22:22 +0300)] 
build: properly detect netinet/ip.h structs

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: fix some statement left from conversion
Alon Bar-Lev [Sat, 7 Apr 2012 17:39:26 +0000 (20:39 +0300)] 
build: fix some statement left from conversion

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: gc usage
Alon Bar-Lev [Sun, 1 Apr 2012 13:46:28 +0000 (16:46 +0300)] 
cleanup: gc usage

Cleanup of "Use the garbage collector when retrieving x509 fields"
patch series.

Discussed at [1].

There should be an effort to produce common function prologue
and epilogue, so that cleanups will be done at single point.

[1] http://comments.gmane.org/gmane.network.openvpn.devel/5401

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: avoid using ~0 - windows
Alon Bar-Lev [Sun, 1 Apr 2012 12:12:37 +0000 (15:12 +0300)] 
cleanup: avoid using ~0 - windows

Use the following constants:
- METRIC_NOT_USED
- TUN_ADAPTER_INDEX_INVALID

Modified: Use MAXDWORD for route loop.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: avoid using ~0 - netmask
Alon Bar-Lev [Thu, 29 Mar 2012 09:16:41 +0000 (11:16 +0200)] 
cleanup: avoid using ~0 - netmask

Use IPV4_NETMASK_HOST constant.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: avoid using ~0 - ipv6
Alon Bar-Lev [Thu, 29 Mar 2012 09:16:40 +0000 (11:16 +0200)] 
cleanup: avoid using ~0 - ipv6

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: avoid using ~0 - generic
Alon Bar-Lev [Thu, 29 Mar 2012 09:16:39 +0000 (11:16 +0200)] 
cleanup: avoid using ~0 - generic

Use limits.h for maximum value.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: flags should not be bool
Alon Bar-Lev [Sun, 25 Mar 2012 11:27:02 +0000 (13:27 +0200)] 
cleanup: flags should not be bool

Discussed at [1][2][3].

[1] https://bugs.gentoo.org/show_bug.cgi?id=297854#c2
[2] https://297854.bugs.gentoo.org/attachment.cgi?id=214304
[3] http://sourceforge.net/mailarchive/forum.php?thread_name=20120325111517.GI1359%40greenie.muc.de&forum_name=openvpn-devel

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoMigrated x509_get_sha1_hash to use the garbage collector
Adriaan de Jong [Tue, 14 Feb 2012 10:11:26 +0000 (11:11 +0100)] 
Migrated x509_get_sha1_hash to use the garbage collector

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: James Yonan <james@openvpn.net>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoMigrated x509_get_serial to use the garbage collector
Adriaan de Jong [Tue, 14 Feb 2012 10:11:25 +0000 (11:11 +0100)] 
Migrated x509_get_serial to use the garbage collector

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: James Yonan <james@openvpn.net>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoMigrated x509_get_subject to use of the garbage collector
Adriaan de Jong [Tue, 14 Feb 2012 10:11:24 +0000 (11:11 +0100)] 
Migrated x509_get_subject to use of the garbage collector

This also cleans up a messy call in pkcs11.c to _openssl_get_subject, as discussed at FOSDEM.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: James Yonan <james@openvpn.net>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoEnable pedantic in windows compilation
Alon Bar-Lev [Wed, 28 Mar 2012 18:43:15 +0000 (20:43 +0200)] 
Enable pedantic in windows compilation

Apparently -ansi undef WIN32 macro.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoFixed off-by-one in serial length calculation
Adriaan de Jong [Tue, 28 Feb 2012 16:29:47 +0000 (17:29 +0100)] 
Fixed off-by-one in serial length calculation

The serial length was one digit too short, resulting in missing digits
at the end of the certificate's stringified serial number.

Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRemove calls to OpenSSL when building with --disable-ssl
Igor Novgorodov [Tue, 28 Feb 2012 11:16:01 +0000 (15:16 +0400)] 
Remove calls to OpenSSL when building with --disable-ssl

Move OpenSSL calls out from the generic crypto layer and into the
OpenSSL specific layer.  Also don't load all algortihms if SSL
isn't enabled.

Error strings will also not be loaded into memory if ENABLE_SMALL
is configured.

Signed-off-by: Igor Novgorodov <igor@novg.net>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: msvc: upgrade to Visual Studio 2010 + fixups
Alon Bar-Lev [Sat, 24 Mar 2012 07:58:36 +0000 (09:58 +0200)] 
build: msvc: upgrade to Visual Studio 2010 + fixups

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: tap: search for tap header
Alon Bar-Lev [Mon, 26 Mar 2012 21:26:36 +0000 (23:26 +0200)] 
build: tap: search for tap header

Windows and solaris has something in common, in both
the tap header is external. So make the Windows tap-windows.h
search common to all platform.

Display an error if we cannot find tap header.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: openbsd: detect netinet/ip.h correctly
Alon Bar-Lev [Mon, 26 Mar 2012 21:26:35 +0000 (23:26 +0200)] 
build: openbsd: detect netinet/ip.h correctly

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: assume dlfcn is available on all supported platforms
Alon Bar-Lev [Mon, 26 Mar 2012 10:34:07 +0000 (12:34 +0200)] 
build: assume dlfcn is available on all supported platforms

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Tested-by: Gert Doering <gert@greenie.muc.de>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: windows: set vendor to openvpn project + cleanups
Alon Bar-Lev [Sat, 24 Mar 2012 06:43:50 +0000 (08:43 +0200)] 
build: windows: set vendor to openvpn project + cleanups

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: enable lzo by default
Alon Bar-Lev [Sat, 24 Mar 2012 07:58:37 +0000 (09:58 +0200)] 
build: enable lzo by default

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: autoconf: misc sockets fixups
Alon Bar-Lev [Sat, 24 Mar 2012 07:58:34 +0000 (09:58 +0200)] 
build: autoconf: misc sockets fixups

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: ax_varargs.m4: fixups
Alon Bar-Lev [Sat, 24 Mar 2012 07:58:33 +0000 (09:58 +0200)] 
build: ax_varargs.m4: fixups

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: use tap-windows.h as external dependency
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:22 +0000 (22:12 +0200)] 
build: use tap-windows.h as external dependency

tap-windows.h is provided by the tap project

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: distribute samples in windows
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:21 +0000 (22:12 +0200)] 
build: distribute samples in windows

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: windows: install version.sh to allow installer read version
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:20 +0000 (22:12 +0200)] 
build: windows: install version.sh to allow installer read version

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: move wrappers into platform module
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:19 +0000 (22:12 +0200)] 
build: move wrappers into platform module

+ Some fixups within the platform.c functions.
- need to check environment set on Windows.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: move console related function into its own module
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:18 +0000 (22:12 +0200)] 
cleanup: move console related function into its own module

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: move inet_ntop(), inet_pton() emulation into compat
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:17 +0000 (22:12 +0200)] 
build: move inet_ntop(), inet_pton() emulation into compat

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: move daemon() emulation into compat
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:16 +0000 (22:12 +0200)] 
build: move daemon() emulation into compat

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: move gettimeofday() emulation to compat
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:15 +0000 (22:12 +0200)] 
build: move gettimeofday() emulation to compat

Remove all references to gettimeofday() from main project.

SIDE EFFECT: mingw will use its own internal gettimeofday().

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: split out compat
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:14 +0000 (22:12 +0200)] 
build: split out compat

compat should not use any of the main project headers or conventions,
it should be a standalone library that provides missing library
functions.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: move out config.h include from syshead
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:13 +0000 (22:12 +0200)] 
build: move out config.h include from syshead

Yet another step in reducing the syshead.h content.

Conditional compilation of sources needs to be based on
a minimum program prefix (config.h only).

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: win-msvc: msbuild format
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:12 +0000 (22:12 +0200)] 
build: win-msvc: msbuild format

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: autoconf: update defaults for options
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:11 +0000 (22:12 +0200)] 
build: autoconf: update defaults for options

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: proper crypto detection and usage
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:10 +0000 (22:12 +0200)] 
build: proper crypto detection and usage

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: proper lzo detection and usage
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:09 +0000 (22:12 +0200)] 
build: proper lzo detection and usage

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: properly process lzo-stub
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:08 +0000 (22:12 +0200)] 
build: properly process lzo-stub

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: proper pkcs11-helper detection and usage
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:07 +0000 (22:12 +0200)] 
build: proper pkcs11-helper detection and usage

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: distribute pkg.m4
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:06 +0000 (22:12 +0200)] 
build: distribute pkg.m4

RHEL and others do not install this globally, so we provide our own copy.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: proper selinux detection and usage
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:05 +0000 (22:12 +0200)] 
build: proper selinux detection and usage

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: autoconf: minor cleanups
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:04 +0000 (22:12 +0200)] 
build: autoconf: minor cleanups

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: properly detect and use socket libs
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:03 +0000 (22:12 +0200)] 
build: properly detect and use socket libs

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: libdl usage
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:02 +0000 (22:12 +0200)] 
build: libdl usage

1. properly detect.
2. Link only required components.
3. No way we don't have LoadLibrary on Windows.
4. ENABLE_PLUGIN should be controlled in autoconf.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: autoconf: commands as environment
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:01 +0000 (22:12 +0200)] 
build: autoconf: commands as environment

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: add libtool + windows resources for executables
Alon Bar-Lev [Wed, 29 Feb 2012 20:12:00 +0000 (22:12 +0200)] 
build: add libtool + windows resources for executables

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: standard directory layout
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:59 +0000 (22:11 +0200)] 
build: standard directory layout

Suitable for mature project.

root   - administrative stuff
doc    - documents
src    - sources
tests  - tests
distro - distro specific files
sample - samples

SIDE EFFECT: many changes to rpm spec.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: remove awk and non-standard autoconf output processing
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:58 +0000 (22:11 +0200)] 
build: remove awk and non-standard autoconf output processing

Replace with simpler environment solution.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: autoconf: remove OPENVPN_ADD_LIBS useless macro
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:57 +0000 (22:11 +0200)] 
build: autoconf: remove OPENVPN_ADD_LIBS useless macro

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: autotools: first pass of trivial autotools changes
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:56 +0000 (22:11 +0200)] 
build: autotools: first pass of trivial autotools changes

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: m4/ax_socklen_t.m4: cleanup
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:55 +0000 (22:11 +0200)] 
build: m4/ax_socklen_t.m4: cleanup

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: m4/ax_emptyarray.m4: cleanup
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:54 +0000 (22:11 +0200)] 
build: m4/ax_emptyarray.m4: cleanup

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: m4/ax_varargs.m4: cleanup
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:53 +0000 (22:11 +0200)] 
build: m4/ax_varargs.m4: cleanup

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: split acinclude.m4 into m4/*
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:52 +0000 (22:11 +0200)] 
build: split acinclude.m4 into m4/*

ax_emptyarray.m4  ax_openvpn_lib.m4  ax_socklen_t.m4  ax_varargs.m4

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: remove windows specific build system
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:51 +0000 (22:11 +0200)] 
build: remove windows specific build system

It will be completely re-written in future

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: rename tap-windows function from win32 to win
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:50 +0000 (22:11 +0200)] 
cleanup: rename tap-windows function from win32 to win

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRemove tap-win32
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:49 +0000 (22:11 +0200)] 
Remove tap-win32

Introduce tap-windows.h which is modified tap-win32/common.h.
Except of function rename, it is the same without the tap_id.
This file should be provided as part of tap-win32 MSI.
For now we hold a copy.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRemove easy-rsa
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:48 +0000 (22:11 +0200)] 
Remove easy-rsa

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRemove install-win32
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:47 +0000 (22:11 +0200)] 
Remove install-win32

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: we need the sample.ovpn in future
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:46 +0000 (22:11 +0200)] 
build: we need the sample.ovpn in future

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: plugins: properly use CC, CFLAGS and LDFLAGS
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:45 +0000 (22:11 +0200)] 
build: plugins: properly use CC, CFLAGS and LDFLAGS

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: rename plugin directory to plugins
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:44 +0000 (22:11 +0200)] 
build: rename plugin directory to plugins

This to avoid conflit with plugin.c rules

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: handle printf style format in mingw
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:43 +0000 (22:11 +0200)] 
build: handle printf style format in mingw

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoUpdate .gitignore
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:42 +0000 (22:11 +0200)] 
Update .gitignore

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: correct place to alter WINVER is at build system
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:41 +0000 (22:11 +0200)] 
build: correct place to alter WINVER is at build system

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agofixup: init.c: add missing conditional for ENABLE_CLIENT_CR
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:40 +0000 (22:11 +0200)] 
fixup: init.c: add missing conditional for ENABLE_CLIENT_CR

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: memcmp.c: remove unused source
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:39 +0000 (22:11 +0200)] 
cleanup: memcmp.c: remove unused source

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: tun.c: fix incorrect option in message (ip-win32)
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:38 +0000 (22:11 +0200)] 
cleanup: tun.c: fix incorrect option in message (ip-win32)

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: crypto_openssl.c: remove support for pre-openssl-0.9.6
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:37 +0000 (22:11 +0200)] 
cleanup: crypto_openssl.c: remove support for pre-openssl-0.9.6

autoconf rejecting this anyway:
----
AC_MSG_CHECKING([that OpenSSL Library is at least version 0.9.6])
<snip>
AC_MSG_ERROR([OpenSSL crypto Library is too old.])
----

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: remove redundant ';'
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:36 +0000 (22:11 +0200)] 
cleanup: remove redundant ';'

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: win32.c: wrong printf format
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:35 +0000 (22:11 +0200)] 
cleanup: win32.c: wrong printf format

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: remove C++ warnings
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:34 +0000 (22:11 +0200)] 
cleanup: remove C++ warnings

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agocleanup: options.c: remove redundant include
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:33 +0000 (22:11 +0200)] 
cleanup: options.c: remove redundant include

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agopackage: rpm: strip should be handled by package management
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:32 +0000 (22:11 +0200)] 
package: rpm: strip should be handled by package management

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: Samuli Seppänen <samuli@openvpn.net>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agobuild: version should not contain '-'
Alon Bar-Lev [Wed, 29 Feb 2012 20:11:31 +0000 (22:11 +0200)] 
build: version should not contain '-'

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agofix warnings in event.c when building for win32-64
Heiko Hund [Thu, 18 Aug 2011 12:12:11 +0000 (12:12 +0000)] 
fix warnings in event.c when building for win32-64

When compiling for 64-bit Windows gcc warns about

  "cast from pointer to integer of different size"

on two occasions in file event.c, due to invalid casting.
This patch removes the type casts and uses the correct
format specifier instead.

Signed-off-by: Heiko Hund <heiko.hund@sophos.com>
Acked-by: James Yonan <james@openvpn.net>
URL: http://article.gmane.org/gmane.network.openvpn.devel/4979
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoremove wrapper code for Windows CryptoAPI function
Heiko Hund [Wed, 17 Aug 2011 15:53:01 +0000 (15:53 +0000)] 
remove wrapper code for Windows CryptoAPI function

The CryptoAPI function CryptAcquireCertificatePrivateKey() was previously
unsupported in MinGW. With recent w32api headers it's now defined, mostly.
Since the code used to load the CryptoAPI DLL is prone to a DLL hijacking
attack [1], it's now a good time to get rid of wrapper completely.

Just a few macros left that may still be undefined on some
systems using the original MinGW headers.

[1] http://isc.sans.edu/diary.html?storyid=9445

Signed-off-by: Heiko Hund <heiko.hund@sophos.com>
Acked-by: James Yonan <james@openvpn.net>
URL: http://article.gmane.org/gmane.network.openvpn.devel/4979
Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoPreparing OpenVPN 2.3-alpha1 release v2.3-alpha1
David Sommerseth [Tue, 21 Feb 2012 10:12:42 +0000 (11:12 +0100)] 
Preparing OpenVPN 2.3-alpha1 release

Signed-off-by: David Sommerseth <davids@redhat.com>
13 years agoRevamp check_file_access() checks in stdin scenarios
David Sommerseth [Mon, 20 Feb 2012 09:31:54 +0000 (10:31 +0100)] 
Revamp check_file_access() checks in stdin scenarios

It was discovered that --management also can take stdin as argument
instead of a file.  Enabled this by revamping the check_file_access()
flags by adding CHKACC_ACPTSTDIN.  Setting this flag will then consider
filenames as 'stdin' as always present.

The other place where 'stdin' was accepted is also modified to use this
flag instead.

Signed-off-by: David Sommerseth <davids@redhat.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
13 years agodefine access mode flag X_OK as 0 on Windows
Heiko Hund [Sat, 18 Feb 2012 19:44:12 +0000 (20:44 +0100)] 
define access mode flag X_OK as 0 on Windows

The _access and _waccess functions in Windows don't know about
X_OK (1). If you pass an uneven mode flag the C runtime's default
invalid parameter handler ends execution of openvpn.

Signed-off-by: Heiko Hund <heiko.hund@sophos.com>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>