I uploaded an android application a few months ago and I will need to upload version-3 soon. But I forgot which key-store file I used to sign the previous APK.
Therefore, how do I check which key-store file I used to sign the APK file?
If you have several keystores with you then you can try making apks with them try uploading the APKs.
If it accepts then you are lucky. This is the original keystone you used while signing the first time.
If you don't have the original keystore then it is not possible as per my knowledge.
Related
Currrently i am using android 3.1.4 and when i try to generate signed apk using Build->Generate signed apk the apk file stores in
/app/release/app-release.apk
And i also configured the build process to automatically sign your APK using Open Module Settings. plz refer here .
And according to this document the location is
/build/app/outputs/apk/app-release.apk
So which apk file is correct/perfect for the play store publication?
/build/app/outputs/apk/app-release.apk
Or
/app/release/app-release.apk
both the APKs have their specific concerns.
the apk generated using normal build can be found here,
/build/app/outputs/apk/app-release.apk
in general, if you're in the development phase then we do not have to generate every time keystore details and all the security details. cause, we just have to test the changes after bugs resolved. so, the best usage of the application found using normal build is to test and debug your app.
while, the apk generated using generate signed apk can be found here,
/app/release/app-release.apk
signed apk requires keystore and password details. so, it is used to upload for your final build. when, you're 100% sure that the application is as per your requirement, only then you should generate a signed apk.
so, the answer for your question is, It is recommended that you upload an apk, which is generated using "Generate Signed APK".
tl;dr = Both are correct
let me Explain how
There is three types of APK
An unsigned APK
A signed Apk = Unsigned APK + Signing certificate key
A debug Apk = Unsigned APK + Debug certificate key
The automatic build process generate the same APK as you manually generate, if you configured it to automatically sign your APK.
so
If we don't want to sign our APK again and again then we can configure to get signed apk every time we build and the generated APK will go into
/build/app/outputs/apk/app-release.apk
and if we use Generate Signed APK
then the default path. (path can be changed)
/app/release/app-release.apk
Even you can generate an unsigned APK and later sign it and release. its also the same
here is the official documentation where it showing how you can sign an unsigned apk
and the last line of this documentation clearly saying
An APK signed with your private key is ready for distribution
Generally developer's find Generate Signed APK manually is better because maybe you made a change and forgot to build/run your code and picked older app-release.apk so generating manually means you are 100% sure that this one is latest
but if you just build and pick auto created release file then it's also correct and latest one
/app/release/app-release.apk
would be the one you're looking for. I found myself in a similar situation not so long ago
I have a .apk file. And I want to get the platform key (with .jks or .keystore format)from this .apk to sign another .apk. Is it possible? If yes, how to do it?
If you mean to sign APK by retrieving all data necessary for signing from another APK ... answer is NO.. you need to get that keystone to sign same or another APK.
Could someone please clarify if I can use a copy (created at release #1) of keystore for signing off a new release (let say release #3) of Android apk, if previous release (#2) was signed using original keystore? Or should I make a backup copy of an original keystore each time when a new release is signed off?
You can use it any time you want, and any copy you want.
The important thing is that once you upload an APK and release it updates ONLY can be signed with the same keystore. You can and in fact you should store your keystore files at multiple places so you don't lose them. We did once and that was awful, would not recommend. :)
You have to use the same Keystore each time you want to create a Signed application using the same Password which you use to create Keystore.
If you use different details for new Keystore you will not be able to update the new build on Google Play. To update new version of same application apk must be signed with same Keystore each time.
You can also create new Keystore each time while signing the application but it is not needed as you can use the same copy of certificate.
I have this signed APK and I need to change the version-code in the manifest, because I lost the keystore ( #*!$##&£!! ).
I've seen the question How can I update the version of an APK which I did not create myself , but no success... please help!
You could use apktool to decompile that apk then change the version in manifest. But the problem is you have to recompile it again then you need to sign the apk with jarsigner. There you need the keystore to sign the apk again. and to update the previous apk you need to use the same keystore.
You can not create new sign apk without KeyStore file.
if Your app new on google play and not more download.
then You want create new sign apk with different package name and new Keystore file.
and upload it on GooglePlayStore.
other options are available but i think it is risky.
I have uploaded on apk file on the google play account,
apk i have created from eclipse by right click on the project and export and put following details in it
password,alias and developer units only.
and i have uploaded successfully on google play account.
But now problem is i have deleted this apk from local and also i am unable to uplaod any other apk if try to update 2nd apk with version code = 2 and version name = 1.0 then also it is giving me error that
The apk must be signed with the same certificates as the previous version.
So please help me to solve this issue now what can i do to upload a new updated apk in this application.
You are not using the same keystore file to sign your apks.
the .apk must be signed with the same private key. If the package name and signing certificate do not match those of the existing version, Market will consider it a new application and will not offer it to users as an update.
Taken from here,
The apk must be signed with the same certificates as the previous version
The only way is to sign your update package apk with the same key which you have used for the previous version. No other go. Google is strict about it.
For the same application you are updating it's version. Then there is
no need of having previous apk file but there should be same keystore
which you have used to sign the first apk file which is on google
play. Also follow the same steps which you have done for first apk
file.
In case you don't have same keystore then :( you simply cannot update the same application as of now.