Problem:
Using JPackage to create an executable for Windows does not work with KeyStore. It returns an error.
Code:
KeyStore.getInstance("Windows-MY");
will throw exception:
java.security.KeyStoreException: Windows-MY not found
at java.base/java.security.KeyStore.getInstance(Unknown Source)
...
Caused by: java.security.NoSuchAlgorithmException: Windows-MY KeyStore not available
at java.base/sun.security.jca.GetInstance.getInstance(Unknown Source) at java.base/java.security.Security.getImpl(Unknown Source)
Running the jpackage for Windows and trying to execute KeyStore.getInstance("Windows-MY");
returns the error above.
Running the application in the IDE without JPackage works fine.