Run the following command in the C: \ Program Files \ Java \ jdk1.6.0 _ 07 \ bin> directory (jdk installation directory) (if environment variables have been configured, enter the following command directly, however, the generated file will be in the directory of drive C.) Enter keytool-genkey-alias android. keystore-keyalg RSA-validity 100000-keystore android. keystore
It indicates that-validity indicates the validity period of the certificate, which is set to 100000 days. The space and the Return key are counted as passwords.
After the command is executed, the android. keystore file is generated in the C: \ Program Files \ Java \ jdk1.6.0 _ 07 \ bin> directory.
Describes how to generate a keystore
Cmd:
Go to the bin directory of jdk. In this way, the android. keystore file will be generated under this directory. We need this file for signature.
C: \ Program Files \ Java \ jdk1.7.0 _ 01 \ bin>
Keytool-genkey-alias android. keystore-keyalg RSA-validity 20000-keystore android. keystore
-Keystore alias generated by alias android. keystore
-Keyalg RSA encryption and digital signature Algorithms
-Validity 1000 valid days
The java sdk 1.5 and 1.6 can both be used. You can find your own JAVA directory.
Enter the keystore password: confirm the password. It is not displayed, but it has already been entered!
Enter the new password again:
What is your first name and last name?
[Unknown]: victor
What is the name of your organization?
[Unknown]: extc
What is your organization name?
[Unknown]: extc
What is the name of your city or region?
[Unknown]: DG
What is the name of your state or province?
[Unknown]: GD
What is the two-letter country code for this unit?
[Unknown]: CN
CN = Mickle, OU = www.ioou.com, O = www.ioou.com, L = Shanghai, ST = Shanghai, C = CN correct?
[No]: Y
Enter the primary password (if the password is the same as the keystore password, press Enter ):
If there is no error, go back to the bin directory of the java jdk to check whether there is an additional file called android. keystore.