Jarsigner: certificate chain not found for

前端 未结 4 1519
日久生厌
日久生厌 2021-02-07 00:00

I have imported a certificate into a private ~/.keystore file:

keytool -list
Enter keystore password:

Keystore type: JKS
Keystore provider: SUN

Yo         


        
4条回答
  •  礼貌的吻别
    2021-02-07 00:11

    Short Answer

    Use your alias key instead of key store like this:

    jarsigner -verbose -keystore [Your signature storage path] -signedjar [signed filename] [unsigned filename] [Your alias key]
    

    More Details

    Here are the easiest way to solve this error:

    1. Go to bin folder .. it may be in this path:

    C:\Users[Your computer name]\jdk\bin

    or this path:

    C:\Program Files\Java\jre1.8.0_77\bin

    1. To prevent issues caused by the configuration of environment variables, please copy both the empty package to be signed, and your key store [the private key for signature] to the bin directory under JDK.

    2. Get your alias key by run this command:

      keytool -keystore [your key store] -list -v

    3. Finally run this command:

      jarsigner -verbose -keystore [Your signature storage path] -signedjar [signed filename] [unsigned filename] [Your alias key]

提交回复
热议问题