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

Consistently load OpenSSL libraries among different platforms. #884

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

Conversation

KostasTsiounis
Copy link
Contributor

@KostasTsiounis KostasTsiounis commented Nov 12, 2024

As part of this pull request, these changes are performed:

  • Allow loading specific user-defined OpenSSL library using the -Djdk.native.openssl.lib option.
  • OpenSSL library loading is consolidated into a single file using ifdefs.
  • The platform-specific MD files are no longer needed and are thus deleted.
  • Additional traces are added to indicate the attempts and actual OpenSSL library laoded.
  • The location of the library loaded is printed.

Moreover, the order of preference for loading a library is updated to follow this order:

  1. Explicitly load what was specified via JVM property. Fail if loading fails.
  2. Search within the Semeru directories for a bundled version.
  3. Search the system for existing libraries and attempt to find the higher version.
  4. If all of the previous steps fail, revert to original Java implementation for crypto.

Co-authored by: Paritosh Kumar paritkum@in.ibm.com
Co-authored by: Kostas Tsiounis kostas.tsiounis@ibm.com

Signed-off-by: Kostas Tsiounis kostas.tsiounis@ibm.com

@pshipton
Copy link
Member

The commit comment mentions jdk.openssl.libName

@pshipton
Copy link
Member

There is a typo as well - porperty

As part of this pull request, these changes are performed:
- Allow loading specific user-defined OpenSSL library using the
-Djdk.native.openssl.lib option.
- OpenSSL library loading is consolidated into a single file using ifdefs.
- The platform-specific MD files are no longer needed and are thus deleted.
- Additional traces are added to indicate the attempts and actual OpenSSL
library laoded.
- The location of the library loaded is printed.

Moreover, the order of preference for loading a library is updated to
follow this order:

1. Explicitly load what was specified via JVM property. Fail if loading
fails.
2. Search within the Semeru directories for a bundled version.
3. Search the system for existing libraries and attempt to find the higher
version.
4. If all of the previous steps fail, revert to original Java
implementation for crypto.

Co-authored by: Paritosh Kumar <paritkum@in.ibm.com>
Co-authored by: Kostas Tsiounis <kostas.tsiounis@ibm.com>

Signed-off-by: Kostas Tsiounis <kostas.tsiounis@ibm.com>
@KostasTsiounis
Copy link
Contributor Author

The commit comment mentions jdk.openssl.libName

Updated to what we discussed.

There is a typo as well - porperty

Fixed that.

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.

3 participants