Google Maps API for Android, getting SHA1 cert instead of MD5

AndroidGoogle MapsMd5Sha1Fingerprint

Android Problem Overview


When I try to get the MD5 fingerprint using keytool, I get a SHA1 fingerprint instead and the Google Maps doesn't recognize it. How do I get the MD5 fingerprint?

Android Solutions


Solution 1 - Android

Use JDK version 1.6 instead of 1.7 because 1.7 generates the fingerprint with SHA1 by default. or you can use (-v) option of the keytool to give you all supported algorithms output and you will find the MD5 in it. for examble : keytool -v -list -keystore [your keystore path] and then enter the password which is [android] by default (you can get the keystore path from Eclipse window>Prefs>Android>build).

Sincerely, DigitalFox

Solution 2 - Android

C:\Program Files\Java\jdk1.7.0_04\bin>keytool.exe -V -list -alias androiddebugkey -keystore "C:\Documents and Settings\IBM\.android\debug.keystore" -storepass android -keypass android

Consider your jdk-bin path in the first path place and your home user directory in the second path. For windows 7 it is like "C:\Users\username.android\debug.keystore"

Use the above command you will get all the keys.

for more details go through this https://stackoverflow.com/questions/9696288/androidgoogle-maps-api-key-signup-md5-certification-key">androidgoogle-maps-api-key-signup-md5-certification-key</a>

Solution 3 - Android

The easiest, full prove and permanent way to get MD5 or SHA1 or SHA256 is as follows_

  1. Update the PATH Environment Variable.
  2. Start Command prompt "Ctrl+R" & enter cmd in RunDailog panel then click ok.
  3. Navigate to the directory where your debug.keystore file resides e.g., C:\Users\Admin\.android path of my debug.keystore file.
  4. Run the following command

C:\<PATH OF YOUR DEBUG.KEYSTORE FILE>>keytool -list -v -alias androiddebugkey -keystore debug.keystore -keypass android -storepass android

e.g., C:\Users\Admin.android>keytool -list -v -alias androiddebugkey -keystore debug.keystore -keypass android -storepass android

output_

Alias name: androiddebugkey Creation date: Sep 20, 2013 Entry type: PrivateKeyEntry Certificate chain length: 1 Certificate[1]: Owner: CN=Android Debug, O=Android, C=US Issuer: CN=Android Debug, O=Android, C=US Serial number: 39ea2d1c Valid from: Fri Sep 20 10:55:39 IST 2013 until: Sun Sep 13 10:55:39 IST 2043 Certificate fingerprints:

     MD5:  85:46:3B:8A:62:02:1D:DB:B6:BF:A1:9F:45:D4:54:C6
     SHA1: 69:AF:B5:D6:14:ED:0B:31:89:6B:BD:0F:CC:3C:4C:57:CE:4C:A1:BC
     SHA256: 57:7F:DE:25:31:38:4B:7F:4B:F1:96:CB:46:75:FC:34:85:E3:03:15:D3:

D7:DE:0E:55:82:1B:21:9F:62:97:4E Signature algorithm name: SHA256withRSA Version: 3

I hope this will help to everyone!

Solution 4 - Android

Try this one in cmd:

First go on this path : C:\Program Files\Java\jdk1.6.0_33\bin

then

Type this command..

C:\Program Files\Java\jdk1.6.0_33\bin > keytool.exe -list -alias androiddebugkey -keystore c:\Users\Mitul.android\debug.keystore -keypass android -storepass android

The blow code will work! try this to get md5 key

C:\Program Files\Java\jdk1.6.0_23\bin>keytool.exe -list -alias androiddebugkey - keystore "c:\Users\Administrator.android\debug.keystore" -storepass android -ke ypass android

instead of path & users administrator give your own

Solution 5 - Android

just export your app in eclipse and the MD5 + SHA1 will be displayed in the window. (just before "finish")

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionBrahadeeshView Question on Stackoverflow
Solution 1 - AndroidDigitalFoxView Answer on Stackoverflow
Solution 2 - AndroidRahul BaradiaView Answer on Stackoverflow
Solution 3 - AndroidRupesh YadavView Answer on Stackoverflow
Solution 4 - AndroidMitul GotiView Answer on Stackoverflow
Solution 5 - AndroidNBAppsView Answer on Stackoverflow