[fpc-devel] OpenSSL v1.1.x DLL loading / Bug 37137
Michael Van Canneyt
michael at freepascal.org
Fri Jun 26 08:43:36 CEST 2020
On Wed, 24 Jun 2020, Wayne Sherman via fpc-devel wrote:
> *Bug Reference:*
> "OpenSSL v1.1.1 could not loaded on Windows platform"
> https://bugs.freepascal.org/view.php?id=37137
>
> 1) I can confirm that the new v1.1.x DLL names are correct. I also checked
> some of the builds linked from the OpenSSL binary's page. The OpenSSL
> commit that discusses the name changes:
> https://github.com/openssl/openssl/commit/520f434b42c83d63d8777075eb66967618551d5b
>
> 2) There is a problem with the loading. The DLLs names have to be handled
> in pairs. If the first DLL fails to load (crypto/util DLL), then both
> should be skipped and the next pair tried. If the second DLL (SSL lib)
> fails to load, the first one needs to be unloaded and the pair skipped to
> try the next pair. Otherwise it is possible to load two DLLs that are not
> matched versions.
>
> Reference master branch code:
> https://github.com/graemeg/freepascal/blob/master/packages/openssl/src/openssl.pas#L5634
This needs to be checked.
>
> 3) I recommend the newest libraries be tried first, working backwards
> towards the oldest.
This is already so ? The version numbers are added from new to old ?
>
> Both #2 and #3 are demonstrated by this patch on the synapse mailing list:
> https://sourceforge.net/p/synalist/mailman/message/36933840/
>
> <https://github.com/graemeg/freepascal/blob/master/packages/openssl/src/openssl.pas#L5634>
> 4) The bug report says "Fixed in Version: 3.2.0", but that appears to be
> incorrect.
I have changed that to 4.0
Michael.
More information about the fpc-devel
mailing list