Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid calling deprecated OpenSSL functions #82

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

emaste
Copy link
Contributor

@emaste emaste commented May 25, 2023

As of OpenSSL 1.1 SSL_library_init() and SSL_load_error_strings() are deprecated. There are replacement initialization functions but they do not need to be called: "As of version 1.1.0 OpenSSL will automatically allocate all resources that it needs so no explicit initialisation is required."

Wrap both calls in an OPENSSL_VERSION_NUMBER block.

As of OpenSSL 1.1 SSL_library_init() and SSL_load_error_strings() are
deprecated.  There are replacement initialization functions but they do
not need to be called: "As of version 1.1.0 OpenSSL will automatically
allocate all resources that it needs so no explicit initialisation is
required."

Wrap both calls in an OPENSSL_VERSION_NUMBER block.
@emaste
Copy link
Contributor Author

emaste commented May 25, 2023

FreeBSD change at https://reviews.freebsd.org/D40273

@emaste
Copy link
Contributor Author

emaste commented May 25, 2023

Fixes #81

@ngie-eign
Copy link

I'm not sure what the support surface is for OpenBSM and I don't remember the exact version of OpenSSL BoringSSL and LibreSSL are based on, but given that all versions of OpenSSL prior to 1.1 are technically unsupported at this point, does it make sense to maybe delete the code entirely?

@emaste
Copy link
Contributor Author

emaste commented May 25, 2023

So far I am aiming for minimal diffs, and plan to make another pass over everything later on including updates to use OpenSSL 3 APIs. In particular I don't want to delete SSL_library_init(); if other pre-OpenSSL-1.1 code remains (I haven't checked whether or not it does, yet).

freebsd-git pushed a commit to freebsd/freebsd-src that referenced this pull request May 26, 2023
As of OpenSSL 1.1 SSL_library_init() and SSL_load_error_strings() are
deprecated.  There are replacement initialization functions but they do
not need to be called: "As of version 1.1.0 OpenSSL will automatically
allocate all resources that it needs so no explicit initialisation is
required."

Wrap both calls in an OPENSSL_VERSION_NUMBER block.

Upstream pull request submitted at
openbsm/openbsm#82

PR:		271615
Reviewed by:	ngie
Event:		Kitchener-Waterloo Hackathon 202305
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D40273
bsdjhb pushed a commit to CTSRD-CHERI/cheribsd that referenced this pull request Aug 9, 2023
As of OpenSSL 1.1 SSL_library_init() and SSL_load_error_strings() are
deprecated.  There are replacement initialization functions but they do
not need to be called: "As of version 1.1.0 OpenSSL will automatically
allocate all resources that it needs so no explicit initialisation is
required."

Wrap both calls in an OPENSSL_VERSION_NUMBER block.

Upstream pull request submitted at
openbsm/openbsm#82

PR:		271615
Reviewed by:	ngie
Event:		Kitchener-Waterloo Hackathon 202305
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D40273
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants