Reputation: 376
I'm using ionic for developing an android app. I jarsigned my app by mistake with an new keystore. As I got the error that the certifikate is unequal by uploading the app to the play store I used my backup keystore file with the same certificate needed in playstore.
Now if I want to jarsign my .apk with the command
jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore app-release-unsigned.apk MyApp.apk alias_name
I get the following error
jarsigner error: java.lang.RuntimeException: keystore load: Invalid keystore format
I googled a lot but I am not sure if any of the solutions could help me. I have to use my old certificate and cannot use a new one because I can't upload it then to playstore.
What do I have to do that it works again?
Upvotes: 0
Views: 6184
Reputation: 1006
Just like the error says, you have an issue with the format of your keystore. Check the -keystore
argument in your jarsigner
command line op. It's an .apk
file when it should be your .keystore
file.
Do like this:
jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore my-release-key.keystore HelloWorld-release-unsigned.apk alias_name
Upvotes: 1