cyclonedds/src
Erik Boasson 6a9ebf88eb OpenSSL 1.0.2 compatibility
This addresses a number of issues with building Cyclone DDS including
DDS Security while using OpenSSL 1.0.2. Compatibility with 1.0.2 is a
courtesy towards those who are unable to move to 1.1.x or later because
of other libraries.

* On Windows, one must include Winsock2.h prior to including the OpenSSL
  header files, or it'll pull in incompatible definitions from Winsock.h
  and that breaks some of the files.

* OpenSSL 1.0.2 requires initializing the library (or more particular,
  loading all the required algorithms) but this is no longer needed in
  OpenSSL 1.1.x. It ends up being needed in a few places and having tons
  of essentially dead initialization code lying around is unpleasant.
  Hence this has been consolidated in a single function and protected
  with ddsrt_once().

* One ought to undo the above initialization on 1.0.2g and older, but it
  is impossible to know whether that can safely be done from a library.
  This is also the reason OpenSSL deprecated all the initialization and
  cleanup interfaces. So if one insists on trying it with such an old
  version, let there be some leaks.

* Thread state cleanup is sort-of required prior 1.1.0, but that suffers
  from the same problems; we'd have to do per-thread cleanup code for
  OpenSSL for any thread that could call into it (which is pretty much
  any thread). So once again, people should just use 1.1.0 or newer.

* There are some interfaces added in 1.1.0 that we use, but a few small
  workarounds those can be made to work on 1.0.2 as well. These also
  were replicated in a number of places and consolidated by this commit.

Signed-off-by: Erik Boasson <eb@ilities.com>
2020-05-25 14:44:24 +02:00
..
core Handling of syntax errors in network partitions 2020-05-19 10:49:26 +02:00
ddsrt OpenSSL 1.0.2 compatibility 2020-05-25 14:44:24 +02:00
idlc Distinguish signed, float in type descriptor 2020-05-16 11:38:05 +02:00
mpt Change PrismTech references to Adlink 2020-03-18 17:31:20 +01:00
security OpenSSL 1.0.2 compatibility 2020-05-25 14:44:24 +02:00
tools Merge remote-tracking branch 'upstream/master' into security 2020-05-11 15:05:46 +02:00
CMakeLists.txt Generate header with compile-time features 2020-03-26 08:46:26 +01:00
features.h.in Generate header with compile-time features 2020-03-26 08:46:26 +01:00