资源大湿 发表于 2017-4-7 20:43

Mac Android签名生成keystore

去到java安装的根目录,即输入cd /Library/Java/Home/bin/
当前用户没有最高权限,在Library文件夹下不能生成任何文件,可以到当前用户目录下生成文件
keytool -genkey -v -keystore android.keystore -alias android -keyalg RSA -validity 20000 -keystore /Users/当前用户的用户名/android_demo.keystore
按照提示输入即可,完整代码如下
xiaomingdeiMac:/ xiaoming$ cd /Library/Java/Home/bin/
xiaomingdeiMac:bin xiaoming$ keytool -genkey -v -keystore android.keystore -alias android -keyalg RSA -validity 20000 -keystore /Users/xiaoming/android_demo.keystore
Enter keystore password:
Re-enter new password:
What is your first and last name?
:Li XiaoMing
What is the name of your organizational unit?
:www.xiaoming.com
What is the name of your organization?
:小明集团
What is the name of your City or Locality?
:广州
What is the name of your State or Province?
:广东省
What is the two-letter country code for this unit?
:86
Is CN=Li XiaoMing, OU=www.xiaoming.com, O=小明集团, L=广州, ST=广东省, C=86 correct?
:yes

Generating 1,024 bit RSA key pair and self-signed certificate (SHA1withRSA) with a validity of 20,000 days
    for: CN=Li XiaoMing, OU=www.xiaoming.com, O=小明集团, L=广州, ST=广东省, C=86
Enter key password for <android>
    (RETURN if same as keystore password):


到这里就可以到当前用户根目录下查看生产的keystore签名文件了

suteam 发表于 2017-4-19 20:43

很不错

老徐 发表于 2017-4-19 21:14

楼主是超人

gywinner 发表于 2017-4-19 21:15

好帖就是要顶

raowei 发表于 2017-4-19 20:45

顶顶多好

老徐 发表于 2017-4-19 21:15

很好哦

j717273419 发表于 2017-5-12 21:22

好帖就是要顶

减肥﹖旭 发表于 2017-5-12 21:01

顶顶多好

apkway 发表于 2017-5-12 20:37

难得一见的好帖

j717273419 发表于 2017-5-12 20:56

很好哦
页: [1] 2 3 4 5 6 7 8 9
查看完整版本: Mac Android签名生成keystore