密钥库更改密码
我目前有一个密钥库,其中有一个只有我应该知道的特定密码。我现在需要向其他人授予对该密钥库的访问权限,因此我想:
1)更改密码,以便我可以与其他人共享并让他们签名
2) 创建一个不同的密码并允许他们使用它进行签名。
这可能吗?以及 - 如果是 - 怎么办?
I currently have a keystore, with a particular password that only I should know. I now need to give access to that keystore to someone else, so I would like to either:
1) Change the password, so I can share it with others and let them sign
2) Create a different password and allow them to sign with it.
Is this possible? and - if yes - how?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(8)
密钥库只有一个密码。您可以使用 keytool 更改它:
要更改密钥的密码:
Keystore only has one password. You can change it using keytool:
To change the key's password:
使用 keytool:
Using keytool:
更改密钥库密码
更改密钥库别名密码
注意:
keystorenam
:密钥库的名称(如果您位于不同的文件夹中,则带有路径)aliasname
:创建时使用的别名(如果名称有空格可以使用\)
例如:
Changing keystore password
Changing keystore alias password
Note:
keystorenam
: name of your keystore (with path if you are in different folder)aliasname
: alias name you used when creating (if name has space you can use\)
For example:
要更改密钥库
mykeyfile
内密钥myalias
的密码:To change the password for a key
myalias
inside of the keystoremykeyfile
:对于完整的编程更改(例如安装程序)并且没有提示
完全披露:我不建议在 shell 中运行此命令行,因为旧密码和新密码将保存在 shell 的历史记录中,并在控制台中可见。
For a full programmatic change (e.g. install program) and no prompting
Full disclosure: I DO NOT recommend running this command line in a shell, as the old and new passwords will be saved in the shell's history, and visible in console.
KeyStore Explorer 是 Java 命令行实用程序 keytool 和 jarsigner 的开源 GUI 替代品。 KeyStore Explorer 通过直观的图形用户界面展示其功能以及更多功能。
KeyStore Explorer is an open source GUI replacement for the Java command-line utilities keytool and jarsigner. KeyStore Explorer presents their functionality, and more, via an intuitive graphical user interface.
如果密钥库包含具有不同密码的其他密钥条目,您也必须更改它们,或者您可以使用以下命令将密钥隔离到不同的密钥库,
If the keystore contains other key-entries with different password you have to change them also or you can isolate your key to different keystore using below command,
这里有很多答案,但如果您尝试在 Android Studio 中更改 Mac 上的 jks 密码。以下是我能找到的最简单的步骤
1) 打开终端并 cd 到您的 .jks 所在的位置
2) keytool -storepasswd -new NEWPASSWORD -keystore YOURKEYSTORE.jks
3) 输入您当前的密码
There are so many answers here, but if you're trying to change the jks password on a Mac in Android Studio. Here are the easiest steps I could find
1) Open Terminal and cd to where your .jks is located
2) keytool -storepasswd -new NEWPASSWORD -keystore YOURKEYSTORE.jks
3) enter your current password