Fix memcpy-less DTLS RX so it really doesn't use memcpy().

It was receiving into a preallocated packet... then using queue_new_packet()
on that buffer which would allocate and copy to a *new* packet. Doh!

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Update translations from Transifex

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Fix up the library documentation in openconnect.h a little.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Update translations from Transifex

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Fix system detection for GNU/kFreeBSD and GNU/Hurd

Define the same library features for all GNU/* environments.  Also use
$host_os for system tests.

Signed-off-by: Mike Miller <mtmiller@ieee.org>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Tag version 3.16

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Invoke vpnc-script with "pre-init" to load tun module if necessary

Shift the os-specific tun setup out into a separate function, just because
it declares local variables and the pre-init script call is now happening
before that in the code block.

Clean up script invocation a little too, and fix the fact that we'd run the
script with "reconnect" reason even if there wasn't a script at all.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Install HTML docs under $(docdir)/html

Signed-off-by: Mike Miller <mtmiller@ieee.org>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Use autoconf's standard $(htmldir) and make everything relative to it

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Really disable static library when appropriate

We need the AC_PROG_LIBTOOL to occur *after* AC_DISABLE_STATIC, or it
doesn't work. And the old comment about having to be before the
conditional NLS bits was probably (hopefully) obsoleted by commit
b976ecb0 which rewrote all that.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Include <string.h> in library.c

Don't know how this escaped giving us a warning before...

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Cope with ancient autoconf by defining $(htmldir) and $(localedir) manually

Otherwise you can't build from git on RHEL5, which has autoconf 2.59

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Update changelog

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Remove out of date openconnect.html

Somewhat overdue...

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Attempt to build against OpenSSL without pkg-config

If we insist on using --with-openssl to do that, it looks for (and
builds) a static library. That's intended for use with a locally-built
OpenSSL source tree. For systems like FreeBSD which lack pkg-config for
an otherwise normally-installed dynamic OpenSSL library, we need to cope
the same way as we do with pkg-config-less zlib.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Don't leave stray zlib in $LIBS

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Don't attempt to configure Legacy IP address on tun device.

This was only setting the Legacy IP address and not IPv6, and it wasn't
setting up any routes or nameservers. It wasn't even setting a *netmask*,
so wasn't even useful in the simple case of a VPN serving a single network
range. I can't think of a single case in which it was actually useful.

This is my response to the patch from Stanislav Sedov which makes the IP
configuration code work on FreeBSD 10. The tun code is a big enough mess
of OS-specific ifdefs already; I don't want it getting even worse, so let's
just rip this bit out.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Make vpnc-script mandatory.

Things won't work without it, and it will also help to make sure packagers
notice that it's needed.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Fix shared/static setup to clarify default setting

Change the variables from their defaults only in the --with-openssl
section.  This leaves the default conspicuous and makes --help show the
correct default behavior.

Signed-off-by: Mike Miller <mtmiller@ieee.org>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Add local implementation of asprintf() for Solaris 10

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>