netblue30 / fdns

Firejail DNS-over-HTTPS Proxy Server
GNU General Public License v3.0
115 stars 29 forks source link

warning: 'ERR_load_BIO_strings' is deprecated: Since OpenSSL 3.0 #79

Open glitsj16 opened 1 year ago

glitsj16 commented 1 year ago

When building fdns from git today I noticed the below warning on my Arch Linux box:

[...]
ssl.c: In function ‘ssl_init’:
ssl.c:142:9: warning: ‘ERR_load_BIO_strings’ is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
  142 |         ERR_load_BIO_strings();
      |         ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/openssl/cryptoerr.h:17,
                 from /usr/include/openssl/crypto.h:38,
                 from /usr/include/openssl/bio.h:30,
                 from ssl.c:22:
/usr/include/openssl/cryptoerr_legacy.h:31:27: note: declared here
   31 | OSSL_DEPRECATEDIN_3_0 int ERR_load_BIO_strings(void);
      |                           ^~~~~~~~~~~~~~~~~~~~
[...]

Nothing fatal, but it might need your attention. Upstream's migration guide mentions OpenSSL now loads error strings automatically so functions like ERRload*(), ERR_func_error_string(), ERR_get_error_line(), ERR_get_error_line_data(), ERR_get_state() are no longer needed.

I'll try creating a patch soonish.