-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
FipsStatus.getMarker method does not work with bootstrap class loader #1904
Comments
What version of the FIPS provider is this with? java -Xbootclasspath/a:bc-fips-2.0.0.jar org.bouncycastle.util.DumpInfo produces: Version Info: BouncyCastle Security Provider (FIPS edition) v2.0.0 |
Looks like the issue is specific to java agents with bc-fips-2.0.0.jar appended to the boot class path using Instrumentation.appendToBootstrapClassLoaderSearch Below are the steps to reproduce this
OpenJDK 64-Bit Server VM warning: Sharing is only supported for boot loader classes because bootstrap classpath has been appended |
If using bootstrap class loader, the FipsStatus.getMarker() cannot work because it relies on system class loader.
Here is the context:
In the FipsStatus.getMarker(final Class sourceClass, final String markerName) implementation:
ClassLoader loader = sourceClass.getClassLoader();
ClassLoader.getSystemResource(markerName).toString();
Is it possible to have an improvement so that this method could work with bootstrap class loader?
sourceClass.getResource(markerName) may not work as bc libs may not have a module name.
Thanks!
The text was updated successfully, but these errors were encountered: