D 的个人博客

全职做开源,自由职业者

  menu

Cannot recover key

 java.security.UnrecoverableKeyException: Cannot recover key 处理

This exception may result from the fact that you had provided a key password that was different from the keystore password



此错误由调用 getKey(alias,aliaspassword)函数抛出。

可能原因为 aliaspassword 的密码不正确,

注意
aliaspassword 必须是 aias 数字证书的密码。而不是 keystore 的密码。