Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Problems getting MD5 fingerprint

I try to generate a MD5 fingerprint to obtain a map api key using Java7.

I do it on the way, described at developer page

"C:\Program Files\Java\jdk1.7.0\bin\keytool" -list -alias androiddebugkey -keystore C:\Users\username\.android\debug.keystore -storepass android -keypass android

The problem is, I'm getting SHA1 Fingerprint and not MD5

androiddebugkey, 01.08.2011, PrivateKeyEntry, 
Certificate fingerprint (SHA1): xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx

Any ideas why?

Thnak you in advance

like image 461
Tima Avatar asked May 15 '26 06:05

Tima


1 Answers

Interesting. Well, you can get the entire cert information using this command.

keytool -list -v -keystore C:\Users\username\.android\debug.keystore

You'll need to enter android as the password when prompted. That will give you everything in the keystore, which should only be one certificate rather than looking for a specific alias. It should show you both an MD5 and a SHA1 fingerprint. Give that a try and let me know.

The only thing I can think of is that jdk1.7's keytool gets information differently than jdk1.6(returns SHA1 by default?). This is just a guess and has not been verified but it is the only thing I can really think of.

Edit: It appears my guess might be correct. JDK 7 changes keytool output

like image 73
Otra Avatar answered May 16 '26 20:05

Otra