Ask a Question

Advanced Search

Solution ID : SO7109

Last Modified : 05/02/2018

Error: "keytool error: java.security.cert.CertificateException: Unsupported encoding"

Problem

Error: "keytool error: java.security.cert.CertificateException: Unsupported encoding"
Error: "Unsupported Encoding"

Cause

Keytool is specific about certificate format

Solution

To import the Code Signing Certificate for Java successfully into your keystore, follow the instructions below:

  1. Add 2 carriage returns at the end of the downloaded certificate file.
     
  2. Edit the Begin and End lines so that only -----BEGIN PKCS#7 SIGNED DATA----- and -----END PKCS#7 SIGNED DATA----- appears.