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

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

Open
insinfo opened this issue Apr 19, 2022 · 2 comments

Comments

@insinfo
Copy link

insinfo commented Apr 19, 2022

I compiled a project with bouncycastle ma when I run the project throws this exception

C:\MyJavaProjects\java_native>C:\MyJavaProjects\java_native\app\build\native\nativeBuild\Example.exe
Exception in thread "main" com.oracle.svm.core.jdk.UnsupportedFeatureError: Trying to verify a provider that was not registered at build time: BC version 1.69. All providers must be registered and verified in the Native Image builder. 
        at com.oracle.svm.core.util.VMError.unsupportedFeature(VMError.java:89)
        at javax.crypto.JceSecurity.getVerificationResult(JceSecurity.java:403)
        at javax.crypto.JceSecurity.getInstance(JceSecurity.java:140)
        at javax.crypto.KeyAgreement.getInstance(KeyAgreement.java:280)
        at net.schmizz.sshj.common.SecurityUtils.registerSecurityProvider(SecurityUtils.java:94)
        at net.schmizz.sshj.common.SecurityUtils.register(SecurityUtils.java:280)
        at net.schmizz.sshj.common.SecurityUtils.isBouncyCastleRegistered(SecurityUtils.java:251)
        at net.schmizz.sshj.DefaultConfig.<init>(DefaultConfig.java:78)
        at net.schmizz.sshj.SSHClient.<init>(SSHClient.java:131)
        at demo.SshjExample.init(SshjExample.java:22)
        at demo.Example.main(Example.java:25)

C:\MyJavaProjects\java_native>
@r1cky33
Copy link

r1cky33 commented Apr 24, 2024

Hi, have you solved this problem? I'm encountering the same issue with bctls-jdk15on 1.70 and GraalVM JDK17 using native-maven-plugin :/

@insinfo
Copy link
Author

insinfo commented Apr 26, 2024

@r1cky33 It's been a long time since I really don't remember how I dealt with it in Java, but from what I remember I think I ended up redoing the application using dart/flutter

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

No branches or pull requests

2 participants