Ashok kumar
Ashok kumar

Reputation: 1

Does JKS supports keys created by Post Quantum algorithms like dilithium3?

I am trying to add my .pfx file to JKS using keytool command and its working with keys generated using RSA but not with keys generated using dilithium algorithm

command : keytool -importkeystore -srckeystore combined.pfx -srcstoretype PKCS12 -destkeystore keystore.jks

error : keytool error: java.security.UnrecoverableKeyException: Get Key failed: 1.3.6.1.4.1.2.267.7.8.7 KeyFactory not available

Upvotes: 0

Views: 307

Answers (1)

Udara Pathum
Udara Pathum

Reputation: 23

It is possible to create a JKS keystores using dilithium3 post quantum algorithm. You need to have bouncycastle bcprov-jdk180n latest version Jar to be used as provider.

keytool -genkeypair -alias your_alias -storetype JKS -keyalg DILITHIUM3 -sigalg DILITHIUM3 -keystore your_keystore.jks -validity 365 -storepass your_keystore_password -keypass your_key_password -provider org.bouncycastle.jce.provider.BouncyCastleProvider -providerpath /path/to/bcprov-jdk18on.jar

Upvotes: 1

Related Questions