Now a days android studio has provided pretty simple and easy GUI for creating key-store from the IDE itself but in case if you have some need for creating it through the command line here is a simple tutorial for the same.
Step 1.
run the follwong command
keytool -genkey -v -keystore my-release-key.keystore -alias hell_alias -keyalg RSA -keysize 2048 -validity 10000
where my-release-key.keystore is the name of the key store that is going to be created.
hell_alias is the name of the alias that will be used latter, key size is the bit size of the key, validity is the no of years for which the key store will be valid.
Once this command is ran terminal will ask for a no of inputs like following
- Enter the password for keystore (input the password whatever you want and conform it by reentering)
- Enter your first name and last name (simply type your name or anything you want for the name).
- Enter name of organisation unit.
- Enter the name of organisation.
- Name of city or locality.
- Name of state or province.
- Two letter country code (ie. 91 for india)
- Now it will prompt if the info above feed is correct (simply type yes and hit enter).
- It will ask for alias password (enter it and conform it).
This is it, you are done you will see the name of your key store file with .kestore extention in your currently directory.
Happy coding :)
0 Comment(s)