Search code examples
delphiopensslindyindy10

Upgrade Indy library to use latest OpenSSL library


What is the process of upgrading Indy library written in Delphi to use the latest OpenSSL library having the newest features (eg. TLS v1.3)?

The last version of Indy library I found uses libssl32.dll and ssleay32.dll DLLs. The latest OpenSSL library produces libssl-1_1.dll and libcrypto-1_1.dll DLLs. By changing the DLL names in Indy libray the dynamic loading of OpenSSL DLLs fails because many functions defined in Indy do not match the functions of OpenSSL DLLs. Thus OpenSSL API was changed.

A far as I understand Delphi source files IdSSL*.pas of Indy library should be upgraded:

  • IdSSL.pas
  • IdSSLDotNET.pas
  • IdSSLOpenSSL.pas
  • IdSSLOpenSSLHeaders.pas
  • IdSSLOpenSSLHeaders_static.pas
  • IdSSLOpenSSLUtils.pas

Solution

  • Due API incompatibilities between the OpenSSL library with the newest features 1.1.x and supported OpenSSL library 1.0.x, Indy code have to be reworked. There is no simple/common process for such upgrade.