Java, IllegalFormatConversionException when importing an SSL certificate

luca 28/11/2017 0

Today I faced a strange problem. I needed to import an SSL certificate in a java keystore, using the “classic” keytool command. I was sure that the format of the certificate was correct, but I always received the following error:

java.util.IllegalFormatConversionException: d != java.lang.String

java-keystore01

The reason of the error is that – in the latest versions of java – by default the keytool command uses the language of the system (in my case italian).

I had to add the parameter -J-Duser.language=en to the keytool command to made it work correctly:

java-keystore02

Leave A Response »

This website uses cookies to ensure you get the best experience on our website maggiori informazioni

Questo sito utilizza i cookie per fonire la migliore esperienza di navigazione possibile. Continuando a utilizzare questo sito senza modificare le impostazioni dei cookie o clicchi su "Accetta" permetti al loro utilizzo.

Chiudi