I am trying to sign my apk file I made using phonegap but I can't figure out how to do it. I can't find good, in-depth directions and I have little programming experience,
I have tried to open eclipse and import the application folder but when I choose it and click finish it doesn't respond!!
So any help would be appreciated.
To Sign Your Android/Phonegap Application Follow the Steps Bellow:
1.) Download and Install Java
You can download and/or update your local java Here.
2.) Set Java_Home directory
Instructions for setting Java_Home directory can be found Here.
3.) Run The Following Command In Command Prompt
You can find your local command prompt either through searching from your start menu (vista and newer) or by opening "run" (Windows Key + R), enter "cmd" and press enter. Then Enter The Following Command:
$ keytool -genkey -v -keystore [**keystore_name**].keystore -alias [**alias_name**] -keyalg RSA -keysize 2048 -validity 10000
4.) Enter/Confirm keystore password.
Enter the keystore password and confirm. (Note the password may not visibly appear while typing into cmd.)
5.) Enter some more information
Follow keytool's instructions, entering needed information as prompted.
6.) Enter Alias Password
Keytool should then ask for the Alias password for your alias name. If it's different than the keystore password, enter and confirm. Otherwise press Return/Enter. (I would mark this password down as you will need it later on)
7.) Confirm Location of Signing Key
After this you should receive a signing key and bellow it will show where it is stored. Mark this location down for future reference.
8.) Add Key/Signing
Next sign in to phonegap, click on the top right corner icon and click "Edit Account". Next under the Signing Keys tab, click the "add a key" button, enter your title/alias, select the keystore file (the file location you marked down in step 7) and click submit key.
9.) Unlocking your Key
Next navigate to Account>Edit Account>Signing Keys Tab and click the lock icon. Supply the certificate password from step six and the keystore password from step 4 and click submit key.
10.) Set Key as Default(Optional)
You can then set your key as the default key either by using the checkbox in the keys list, or from within your application's details selecting the key you uploaded and unlocked.
More Info
You can also find more information Here if you would like to dig deeper. Also this instruction is illustrated from the Android Signing article which re-iterates the instructions above as well as providing more sources if you are still having issues.
Thanks #CalebB
1.) Add Key/Signing
sign in to phonegap, click on the top right corner icon and click "Edit Account". Next under the Signing Keys tab, click the "add a key" button, enter your title/alias, select the keystore file (the file location you marked down and click submit key.
2.) Unlocking your Key
Next navigate to Account>Edit Account>Signing Keys Tab and click the lock icon. Supply the certificate password from step six and the keystore password from step 4 and click submit key.
Now you got your app signed and ready for market upload
Related
I'm trying to publish an update to an Android app that was originally published to the store back in 2014. I still have the Keystore file, but none of the development environment (e.g. Eclipse).
I originally thought I forgot the Keystore password, but then remembered that that password was empty. But yet, Android Studio won't let me use a Keystore with an empty password. So I needed to do a good bit of research to find information on how I could change this... I finally came across https://www.c-sharpcorner.com/blogs/forgot-keystore-passwordjks-file-you-can-still-recover-it which gave an example of changing from a blank password.
Once I changed this password, I was then able to get past the 'Password verification failed' message I was receiving when generating a signed app bundle through Android Studio.
The problem is now that I received the 'Cannot recover key' message when generating a signed app bundle. Doing research, this seems to be when the alias key password has been input incorrectly. I was nearly positive that I was using the correct password (the same one that I changed the Keystore password above to) but yet it won't let me. Is there any way to overcome this? As I said above, I don't have access to the gradle or logs from the development environment... and I really don't want to have to upload a new app to the store.
Any help would be greatly appreciated.
I would suggest you try opening both keystore files you have (the one with empty password and the one with the password) with Keystore Explorer.
Note that there are two sets of passwords usually with a '*.jks' file format keystore, one for the keystore having your keys or aliases, and another for unlocking a key or an alias inside the keystore, they can be different and you need to have both when signing. So also try unlocking the key or the alias in the keystore by right clicking on it and selecting "unlock" inside Keystore Expolrer.
Getting the right passwords will then let you make amends such as re-setting the password of the keystore, re-setting the password of a key or alias, or even create a new keystore completely and copy the key or alias into it, just make sure to save a copy with backups every step of the way so not to lose your key(s).
On Android studio, I have fully completed my code and have tested it on my physical device. I have not generated an apk file yet. I have searched around on StackOverflow and all I know now is that I need to export signed to release it on the play store. Now I'm staring at a form not knowing what anything does.
Someone explain please
EDIT: The solution --> developer.android.com/studio/publish/app-signing.html
You have to create a new keystore to use when signing...there is a "Create New" button on that form.
Once you have created the keystore, you will know the information to use to complete this form(make sure you keep track of that, once you have signed you app with this keystore, and uploaded to the Play store, it is permanent, if you forget it you will be in trouble).
In the menu bar, click Build > Generate Signed APK.
Select the module you would like to release from the drop down, and click Next.
On the New Key Store window, provide the following information for your keystore and key.
Keystore
Key store path: Select the location where your keystore should be created.
Password: Create and confirm a secure password for your keystore.
Key
Alias: Enter an identifying name for your key.
Password: Create and confirm a secure password for your key. This
should be different from the password you chose for your keystore
Validity (years): Set the length of time in years that your key will
be valid. Your key should be valid for at least 25 years, so you can
sign app updates with the same key through the lifespan of your app.
Certificate: Enter some information about yourself for your
certificate. This information is not displayed in your app, but is
included in your certificate as part of the APK.
Once you complete the form, click OK.
On the Generate Signed APK Wizard window, select a keystore, a
private key, and enter the passwords for both. (If you created your
keystore in the last step, these fields are already populated for
you.) Then click Next.
On the next window, select a destination for the signed APK(s),
select the build type, (if applicable) choose the product
flavor(s), and click Finish.
Go to Buid (menu bar) -> Generate Signed APK and follow the steps shown in the wizard.
Updating from my comment below:
Select a keystore if you have one else create one using the provided button. Enter the passwords in this window again (same as ones you provide when creating the keystore). Make sure you select a date in far future for the certificate validity otherwise you'll not be able to sign your apk after the certificate expires
I have been able to successfully develop an application that uses Facebook SSO with a debug key. When I released the app for testing the Facebook SSO no longer works. I need a new Facebook Key that is not a debug key. My problem is, I do not know how to generate it. Any help would be much appreciated.
I am using windows 7 and eclipse.
Here is what you do to create a new key and to sign your app for distribution.
1) Right-click on your project in the Package Explorer section of Eclipse and select Android Tools > Export Signed Application Package...
2) Go through the wizard, make sure your project is selected as the one to export
3) Next step is to create a new keystore. Specify the path and what you want the password to be
4) You can change the alias if you want, but default is "android" which is sufficient. Set a password for this alias, set the validity of this key (between 0-1000 years), and at least your first and last name. You can also add any other details you want associated with this key (not required, however).
5) Finish the procedure by specifying the path to where you want to export your APK to be. Press Finish, Eclipse will take a while to package your app. Once it's done, you'll have your new key at the path you specified, as well as an APK file signed by that new key.
Let me know if that helps!
I'm running into a strange error - I'm exporting an Android application in Eclipse using a keystore I had previously created and used. Now when I try to export a different application using the existing keystore, I'm unable to enter the second password. Any idea why?
You mean, the key password (as opposed to the keystore)? Then you've probably mistyped the keystore password.
If you mean that the second password box on the keystore password screen is greyed out, that's by design. The same screen is used to create a new keystore with a password and open an existing one (providing a password). You only need two copies in password creation scenario.
Does anybody know how (and if) you can change the password used to sign android builds?
We have a live app, but want to change the signing password. The problem is that we don't want to force our users to reinstall the app (if we use a new key users won't be able to install the new build as an update to the original app).
I've looked all over the android documentation, but have been unable to find anything even related to the subject (except for making a new key...).
Actually, this is possible:
keytool -storepasswd -keystore my.keystore
You can change the key password , if you have the old password. What you need to run is the following command :
keytool -keypasswd -alias "key_alias" -keypass "old_pass" -new "new_pass" -keystore "your_keystore_path"
This is not possible. It is the signing key that identifies you as the original author and not an imposter. The "how do I recover my lost key" question comes up frequently, and the only answer is to start over with a new application.
If you still have the original signing key, you could release an update to your application which exports user data used by your program, and then release a new app under a new key which can import it, so at least they'd be able to keep their data. Your migration update under the old key could even use an intent to send the the user to the market download page for the new application.