Recent

Author Topic: OpenSSL/LibreSSL version deprecation and function names  (Read 1054 times)

trev

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2020
  • Former Delphi 1-7, 10.2 user
OpenSSL/LibreSSL version deprecation and function names
« on: August 15, 2020, 08:09:45 am »
When using
Code: Pascal  [Select][+][-]
  1. SSLeayversion(0);
there is a deprecation warning:

Quote
unit1.pas(59,15) Warning: Symbol "SSLeayversion" is deprecated: "For 1.1+ use OpenSSL_version"

When using
Code: Pascal  [Select][+][-]
  1. SSLeay_version(0);
there is no deprecation warning.

The deprecation warning for the first variant suggests using OpenSSL_version, but there is no OpenSSL_version() function. There is, however, an OpenSSLGetVersion function.

It would appear to me that:
1) The second SSLeay variant needs a deprecation warning; and
2) The deprecation warning in both instances should suggest OpenSSLGetVersion.

Am I confused? ;)

Bi0T1N

  • Jr. Member
  • **
  • Posts: 85
Re: OpenSSL/LibreSSL version deprecation and function names
« Reply #1 on: August 15, 2020, 11:08:38 am »
I've already provided a patch to fix the deprecation warning and also the loading of the OpenSSL_version.

However, the function function SSLeay_version(t: cint): PChar; has the same name than the  SSLeay_version function from OpenSSL method prior 1.1.x so maybe it was just added for convenience without seeing that _SSLeayversion already exists (or the way around)?
I think it should be deprecated as well (better for backward compatibility than removing it) and changed to use _SSLeayversion as it automatically links to OpenSSL_version if SSLeay_version isn't available anymore.
« Last Edit: August 15, 2020, 11:13:47 am by Bi0T1N »

 

TinyPortal © 2005-2018