我正在签署 jar 文件。由 VeriSign 提供的证书。
它提供2个证书:aplha-primary.cer
and aplha-secoandary.cer
我使用以下命令生成密钥库文件:
keytool -importcert -v -alias -primary -keystore keystore/keystore.jks -file aplha-primary.cer
and
keytool -importcert -v -alias -secoandary -keystore keystore/keystore.jks -file aplha-secoandary.cer
它被导出到密钥库文件。
当我尝试签署 jar 文件时,它给出了如下异常
[signjar] jarsigner: Certificate chain not found for: must
reference a valid KeyStore key entry containing a private key and corresponding
public key certificate chain.
jarsigner -keystore keystore.jks -storepass **** -keypass ****** Uploader.jar alpha-primary
jarsigner: Certificate chain not found for: alpha-primary. alpha-primary must reference a valid KeyStore key entry containing a private key and corresponding public key certificate chain.
我认为您丢失了私钥。
使用非对称加密对 jar 进行签名。
证书仅包含公钥。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)