Skip to content

Conversation

@kslex
Copy link
Contributor

@kslex kslex commented Jan 11, 2024

说明

由于5.x的ProviderFactory中注册了BouncyCastleProvider,导致在外层利用org.graalvm.nativeimage.hosted.Feature注册的BouncyCastleProvider实际也无效,打包出来的graalvm应用也会报错

com.oracle.svm.core.jdk.UnsupportedFeatureError: Trying to verify a provider that was not registered at build time: BC version 1.7. All providers must be registered and verified in the Native Image builder

参见 #2825#3456
可能涉及#2631

修改描述(包括说明bug修复或者添加新特性)

  1. [bug修复] 先从已注册的provider中查找BC,如果为空才通过SecureUtil.addProvider(provider)注册BC

提交前自测

更改之后,在本地使用GraalVM JDK 17.0.9,在Win10环境打包出来的应用报错消失

@looly
Copy link
Collaborator

looly commented Jan 16, 2024

good job!!

@looly looly merged commit 96fd4e8 into chinabugotech:v5-dev Jan 16, 2024
@looly looly added the bug label Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants