1

when i try to get MD5 hash by using

C:\Program Files\Java\jre7\bin>keytool -list -alias androiddebugkey -keystore "C:\Users\learnwhat.android\debug.keystore" -storepass android -keypass android

only get SHA1 hash i need MD5 hash to in goole Map api key sing up. how i can get MD5 hash in jdk1.7.0_09?.

learnwhat
  • 157
  • 2
  • 15

3 Answers3

1

Add -v with command if you are using jre7 for getting MD5 hash for Google Map. this command return you both MD5 and SHA1 :

 C:\<YOUR_JDK_PATH\bin>keytool -v androiddebugkey -keystore "C:Users\YOUR_NAME\.android
\debug.keystore" -alias alias_name -storepass android -keypass android
ρяσѕρєя K
  • 130,641
  • 51
  • 193
  • 212
  • What do u mean? but i got both MD5 and SHA1 on my console – ρяσѕρєя K Nov 28 '12 at 09:34
  • if you have any issue then you can see this image for reference http://i.stack.imgur.com/7jKLb.png – ρяσѕρєя K Nov 28 '12 at 09:36
  • @ρяσѕρєя K : You forgot to put -alias before androiddebugkey. Is it not the command this?: keytool -list -v -keystore keystore.jks -alias alias -storepass storepass -keypass storepass, and this is not giving MD5. – Abhinav Saxena Sep 26 '18 at 07:57
  • @ρяσѕρєя K: I am not getting errors: just not getting MD5. It is not working: on my console, where the version is --> java version "10.0.2" 2018-07-17 Java(TM) SE Runtime Environment 18.3 (build 10.0.2+13) Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode) – Abhinav Saxena Sep 26 '18 at 09:07
  • Can you share with us the link to jre7/jdk7 so that we can have the MD5 at least (place and share from your google drive)? It will be a great help. – Abhinav Saxena Sep 26 '18 at 10:14
0

using the following command:

keytool -v -list -alias androiddebugkey -keystore debug.keystore

-v will force keytool generate md5, sha1, sha256

ray_linn
  • 1,350
  • 10
  • 14
  • It is not working: on my console, where the version is --> java version "10.0.2" 2018-07-17 Java(TM) SE Runtime Environment 18.3 (build 10.0.2+13) Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode) – Abhinav Saxena Sep 26 '18 at 09:04
0
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 likeC:\Users\username.android\debug.keystore

Use the above command you will get all the keys.

https://developers.google.com/android/maps-api-signup

http://mirnauman.wordpress.com/2012/01/30/using-google-maps-in-android-development-tutorial-part-1/

http://mirnauman.wordpress.com/2012/01/26/how-to-get-google-maps-api-key-for-android-issues-and-errors-solved/
Jatinkumar Patel
  • 1,693
  • 2
  • 15
  • 35