0
0
mirror of https://github.com/OpenVPN/openvpn3.git synced 2024-09-20 12:12:15 +02:00
Commit Graph

250 Commits

Author SHA1 Message Date
James Yonan
06acd86d29 Added core support for PEM private key passwords. 2012-11-15 22:48:13 +00:00
James Yonan
5a5a18942a Added parser size validation constants in
openvpn/client/cliconstants.hpp
2012-11-12 01:52:03 +00:00
James Yonan
3ca3a857bd Initial HTTP proxy implementation in core, with support for
non-authenticated proxies and Basic Auth.

Includes new PROXY_ERROR and PROXY_NEED_CREDS events.

Still to do: Digest and NTLM auth.
2012-10-24 06:38:20 +00:00
James Yonan
0cb153f89b Minor additions/changes to test scripts/docs. 2012-10-07 08:55:51 +00:00
James Yonan
cf70bee986 In proto.cpp test code, default to OpenSSL server. 2012-09-26 01:33:41 +00:00
James Yonan
b88790efef iOS client changes:
* Updated to Xcode 4.5 and tested client build on iOS6.

* Note that it is no longer necessary to copy the private
  SystemConfiguration header files for the VPN API into the
  Xcode tree.  The OpenVPN Xcode project file will now
  reference them directly from the ovpn3 tree.

* Note that in Xcode 4.5, the iPhoneOSProductTypes.xcspec file that
  must be edited to allow bundle signing is now a binary plist.
  Use the Mac plutil tool to convert it to JSON so it can be edited
  then convert back to binary:

  $ cp iPhoneOSProductTypes.xcspec iPhoneOSProductTypes.xcspec.backup
  $ plutil -convert json -r iPhoneOSProductTypes.xcspec
  [ edit iPhoneOSProductTypes.xcspec according to instructions in
     ovpn3/doc/Build_VPN_App_and_Plugin.pdf ]
  $ plutil -convert binary1 iPhoneOSProductTypes.xcspec

* The ARM assembler provided in Xcode 4.5 is no longer able to
  assemble the Minicrypto ASM algorithms.  As a workaround, before
  updating to Xcode 4.5, preserve the previous clang binary by
  copying it to ~/clang3/clang -- the build-minicrypto script will
  expect it to exist.  This is the version of clang that must be used:

  $ ~/clang3/clang --version
  Apple clang version 3.0 (tags/Apple/clang-211.10.1) (based on LLVM 3.0svn)
  Target: x86_64-apple-darwin11.4.2
  Thread model: posix

* Make sure to update your PATH to include the new Xcode 4.5 clang and
  rebuild all libraries.  I found that updating to Xcode 4.5 left the
  old clang in /usr/bin.  The Xcode 4.5 clang should show this version
  info:

  $ clang --version
  Apple clang version 4.1 (tags/Apple/clang-421.11.65) (based on LLVM 3.1svn)
  Target: x86_64-apple-darwin11.4.2
  Thread model: posix

* Added $O3/scripts/mac/build-all script to build all Mac/iOS
  dependencies.
2012-09-25 21:04:27 +00:00
James Yonan
6037a4d488 Minor fix to test client. 2012-09-22 19:11:52 +00:00
James Yonan
dcd62a79e6 Allow test/ssl/proto.cpp to be run on Mac OS X with PolarSSL
used as both client and server implementation.

Added DH support to PolarSSL.

Added CLIENT_NO_RENEG and SERVER_NO_RENEG flags to test code
in proto.cpp to allow scenarios to be tested where either
the server, client, or both initiate renegotiation.

Updated test/ovpncli/cli.cpp with new command line options
and will now run on Mac OS X.

Updated Android and iOS build systems to no longer include
any LZO support, and to include Snappy support instead.
2012-09-15 06:56:18 +00:00
James Yonan
48ab9cbbe9 Added our own system() implementation to allow args to be passed as
array instead of concatenated string, and to resolve issue on OS X
where signals were being ignored after system() was called.

C++ iterators incremented in a for statement should usually use
a preincrement syntax.
2012-09-12 04:24:05 +00:00
James Yonan
54a534d347 Fixed build script to work again on OS X.
Implement our own wrapper around ::system().
2012-09-11 23:51:37 +00:00
James Yonan
1ba895a6a0 Added NO_LZO preprocessor flag to disable inclusion of all LZO
functionality (including LZO-Asym) except for LZO stub:

NO_LZO   -- disable all LZO functionality except for stub
HAVE_LZO -- use LZO library for compression/decompression
default  -- use LZO-Asym decompressor (no compression)

Added init_process call to start of test/ovpncli/cli.cpp
2012-09-11 08:45:27 +00:00
James Yonan
58efad3b74 Updated linux scripts to work with latest core and library
organization.

Added scripts under scripts/linux for building dependent
libraries.

Added test/ovpncli/cli.cpp to provide a command line client that
exercises ovpncli.hpp API and can be built via build script.
2012-09-09 23:10:20 +00:00
James Yonan
da1ae7be57 More additions to debugging code for KeyContext state
transitions in proto.hpp.
2012-08-31 21:39:01 +00:00
James Yonan
0622cd2878 Minor refactoring to help bracket rare session invalidated
exception in proto.hpp.
2012-08-31 06:50:43 +00:00
James Yonan
7331ee349b Full iOS beta for OpenVPN Connect. 2012-08-01 12:28:13 +00:00
James Yonan
eccd2cf64f Extended build script to build static libraries.
First version of static libovpncli tested on
iPad (without tun support yet).
2012-05-29 21:15:28 +00:00
James Yonan
2206210562 Misc fixes to update PolarSSL support for 1.1.3. 2012-05-29 16:29:11 +00:00
James Yonan
7b55f4d767 Refactored Mac build scripts to easily switch between OS X, iOS, and iOS simulator. 2012-05-27 09:55:44 +00:00
James Yonan
dafe931877 Build script changes when CLANG=1:
* use -fvisibility=hidden
* use -O4 (LTO) by default
2012-05-23 04:45:01 +00:00
James Yonan
53fa94260f Added clang/LLVM support. 2012-05-22 12:25:33 +00:00
James Yonan
130364c1a5 Add sha2/sha4 to PolarSSL/OpenSSL bridge.
Clean up PolarSSL build scripts, allow testing target.
2012-03-25 22:07:45 +00:00
James Yonan
ca680ba568 Added capability for PolarSSL to use OpenSSL ciphers/digests. 2012-03-23 20:04:33 +00:00
James Yonan
1531bb6f8f Implemented AppleCryptoAPI for Mac. 2012-03-15 12:13:16 +00:00
James Yonan
c4d19c69ea Minor reorg in SSLContext classes. 2012-03-14 03:24:45 +00:00
James Yonan
1b0088ab2e PolarSSL support fully implemented (except for External PKI). 2012-03-14 00:51:40 +00:00
James Yonan
801bfae881 Added Polar SSL crypto support via PolarSSLCryptoAPI. 2012-03-13 04:51:52 +00:00
James Yonan
34dc950815 Core refactor to abstract random and crypto APIs using
static polymorphism.  Only OpenSSL crypto API is
presently implemented.  Still need to implement Apple
and PolarSSL.
2012-03-12 12:24:40 +00:00
James Yonan
74503a4efa Started PolarSSL port. Initially just add RNG support.
Because PolarSSL RNG requires state object, add state
objects for all other RNG providers (OpenSSL, Apple SSL)
to maintain a polymorphic model.
2012-03-11 12:09:25 +00:00
James Yonan
da248a8fbd Search/replace of:
std::exception& e

to:

  const std::exception& e
2012-02-17 19:28:44 +00:00
James Yonan
1f5e50d733 Implemented OpenVPNClient stats methods.
Simplified autologin sensing.
Java test client will now dump stats on exit.
2012-02-12 23:09:28 +00:00
James Yonan
f13ed3e7a8 Implemented Java client using Swig. 2012-02-11 14:02:51 +00:00
James Yonan
f57c9da3a8 Added QUIET option to proto.cpp.
Other minor fixes to proto.cpp.
2012-02-07 12:56:32 +00:00
James Yonan
e7a5d9f55b Start process of moving client logic out of cli.cpp into
general-purpose classes.

Rename ProtoStats to SessionStats and make it more flexible
by using an abstract base class model.

Add a client event queue for the beginnings of a client-backend
API.

Added logic to ProtoContext to invalidate session on certain
kinds of errors in TCP that would be normally be okay in UDP
such as HMAC_ERROR, DECRYPT_ERROR, etc.

Add some alignment adjustment logic for READ_LINK_TCP (3 bytes)
and READ_LINK_UDP (1 byte).
2012-02-04 10:24:54 +00:00
James Yonan
d9e8a028c8 Ported core to Windows except for TAP driver support. 2012-01-25 08:32:27 +00:00
James Yonan
29bc40bf09 Added TCP transport support.
Disable retransmission of control channel packets
when running in TCP mode.
2012-01-20 23:13:48 +00:00
James Yonan
ac32190acf Minor changes to proto.cpp on Apple to conform with new
SSL context Config class semantics.
2011-12-18 11:33:15 +00:00
James Yonan
7371bd8e14 First working version of cli that can be entirely driven from config
file.  Currently limited to UDP, runs only on Linux, and supports
pushed redirect-gateway but not route directives.
2011-12-18 10:50:08 +00:00
James Yonan
fb163b65f4 ProtoContext object can now be reused via reset() method.
Fixed rare bug where client receives auth, goes ACTIVE, but the ACK
response back to the server is dropped causing the server to receive
post-ACTIVE app messages from the client while it's still stuck
in the S_WAIT_AUTH_ACK state.
2011-12-17 10:53:21 +00:00
James Yonan
6260957c37 Added AES-NI support.
Disable logging in Packet ID code unless OPENVPN_DEBUG_PACKET_ID
is defined.
2011-12-17 05:06:39 +00:00
James Yonan
990231b226 First successful negotiation with AS.
Still need to parse and apply PUSH_REPLY options.
2011-12-16 10:02:15 +00:00
James Yonan
c8f7b0ff2f Keepalive implementation. 2011-12-15 08:48:14 +00:00
James Yonan
3bcc32f696 Implemented auth methods in ProtoContext. 2011-12-14 16:20:07 +00:00
James Yonan
44ee74f374 Added compression framework.
Implemented LZO_STUB compressor.

Added methods to generate options and peer info strings.
2011-12-14 11:34:33 +00:00
James Yonan
3f73d56afb Added some string parsing classes/functions for parsing OpenVPN options
given as a comma-separated list.
2011-12-13 19:51:29 +00:00
James Yonan
1b5fa38adb Comment additions.
Catch buffer exceptions and increment BUFFER_ERRORS.
2011-12-13 11:13:27 +00:00
James Yonan
1aa65c259b Implemented soft reset in proto.hpp. 2011-12-13 04:46:56 +00:00
James Yonan
d2acef57e2 Minor README edit. 2011-12-11 08:34:26 +00:00
James Yonan
f3e9239d80 Full-protocol unit test using ProtoContext, w/o soft resets.
Test in test/ssl/proto.cpp.
2011-12-11 08:28:55 +00:00
James Yonan
3684fe3c05 ssl.cpp test should include crypto-lib-independent
gencrypto/gensslctx.hpp instead of openssl/ssl/sslctx.hpp.
2011-11-25 06:08:19 +00:00
James Yonan
e56f1c6b11 Added OpenSSLContext data transfer test. 2011-11-24 10:47:11 +00:00