Lost my debug.keystore due to a new installation of Xamarin. Can I restore it?

I am using for demo purposes the APK made by Xamarin and signed with debug.keystore by default. Due to a new installation of Xamarin, the keystore is changing, and now I can’t upgrade the new version of apk because I encountered a "Application not Installed" error. For several reasons, I do not want my users to uninstall the previous application, losing their data. I agree that I do not need to use a debug key for release (I learned this lesson), but is there a way to recreate the previous debug.keystore file by signing it and one of the applications?

This is the output of the keytool debug.keystore file:

Nome alias: androiddebugkey Data di creazione: 3-apr-2016 Tipo di voce: PrivateKeyEntry Lunghezza catena certificati: 1 Certificato[1]: Proprietario: CN=Android Debug, O=Android, C=US AutoritÓ emittente: CN=Android Debug, O=Android, C=US Numero di serie: 76df3d0d Valido da: Sun Apr 03 15:22:52 CEST 2016 a: Tue Mar 27 15:22:52 CEST 2046 Impronte digitali certificato: MD5: 4C:00:43:61:97:17:DF:B1:95:42:37:53:30:1A:A4:AC SHA1: D5:48:B9:2A:09:66:58:B8:38:16:88:60:47:F3:BF:87:2C:6B:3F:5E SHA256: 58:36:AF:FB:45:2B:E8:9E:C3:8D:F4:77:75:FF:F6:6E:84:69:3E:06:35:37:45:F5:D3:65:A9:4B:68:22:98:AC Nome algoritmo firma: SHA256withRSA Versione: 3 Estensioni: #1: ObjectId: 2.5.29.14 Criticality=false SubjectKeyIdentifier [ KeyIdentifier [ 0000: 44 00 83 0D B8 9B 86 88 91 A0 14 D0 8D 72 39 83 D............r9. 0010: ED F1 7D E7 .... ] ] 

and this is my fingerprint of the ANDROIDD.RSA application:

 AutoritÓ emittente: CN=Android Debug, O=Android, C=US Numero di serie: 2f716439 Valido da: Mon Sep 14 19:26:58 CEST 2015 a: Wed Sep 06 19:26:58 CEST 2045 Impronte digitali certificato: MD5: A3:FF:BC:BA:EF:72:BC:89:1C:42:6A:99:09:B7:C9:EE SHA1: 8D:16:7B:03:99:8A:4F:1C:F4:AC:E1:7D:6A:18:62:58:74:FC:0E:CB SHA256: D1:37:98:26:74:F7:58:C7:06:17:4B:9E:3A:76:C9:23:6B:D9:D4:38:22:6A:9A:87:82:6A:58:2A:F7:2E:94:B6 Nome algoritmo firma: SHA256withRSA Versione: 3 Estensioni: #1: ObjectId: 2.5.29.14 Criticality=false SubjectKeyIdentifier [ KeyIdentifier [ 0000: E3 BB C0 63 F2 60 C6 B0 94 2A 29 68 36 F0 A8 A8 ...c.`...*)h6... 0010: 1E 97 B6 D3 .... ] ] 

So the question is: with this information, can I recreate the previous debug.keystore to smoothly update applications?

Thank you very much for your attention.

Regards, Danilo

+1
xamarin xamarin.android keytool
Apr 11 '16 at 16:39
source share
1 answer

You cannot restore the old one (unless you perform a system restore / etc). Therefore, you just need to create a new one:

keytool -genkey -v -keystore debug.keystore -alias androiddebugkey -storepass android -keypass android -keyalg RSA -validity 14000

Then you can put this in the appropriate directory:

Windows: https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/MD5_SHA1/#Windows

Mac: https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/MD5_SHA1/#OSX

+2
Apr 11 '16 at 16:48
source share



All Articles