Hello I have tried this many different ways and have followed the tutorial at
http://developers.facebook.com/docs/guides/mobile/#android
I am running windows 7 64bit and I have downloaded Cygwin and inputed
$ keytool -export -alias androiddebugkey -keystore "C:\Users\manley85\.android\
debug.keystore" | openssl sha1 -binary | openssl base64 -a -e
Enter keystore password: android
I use the sam alias (androiddebugkey) when I sign and export the package. The keystore is pointed to where the default location of the keystore I use:
"C:\Users\manley85\.android\debug.keystore"
after I sign and export I take the key hash that is outputed and input in my Developers page on FB in Mobile and Devices/Settings/Key hash
The problem that I am having is that before when I was doing everything wrong I believe it was saying “invaid-key” so I’ve been doing this way which I believe is correct, now it is saying:
FaceBook-Authorize Login Failed: The Server failed to communicate Try Again
which leads me to believe that the key is correct but now there is some type of communication error? I’ve also inputed the (wrong key hash/no key hash) into the facebook mobile settings key hash and will get
(“invalid-key”)
But when doing it the way I just explained above it outputs
“Login Failed… etc”
I’ve also uninstalled my facebook each and everytime as there has been issues with facebook not allowing this to work. I’ve ran this on my dell streak, android one and samsung galaxy tab and get the same issue.
I just went through all this. Summary:
1 Do what it says at http://developers.facebook.com/docs/guides/mobile/#android
2 You should have Cygwin installed and OpenSSL. You can install OpenSSL with Cygwin by selecting the OpenSSL option in the Cygwin installation
3 In Cygwin run:
keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore | openssl sha1 -binary | openssl base64
— without newline characters. You can copy it from here.
4 So far you have generated the hash for the standard Android debug key. With this the Facebook example app will run in the emulator (at least it does for me)
5 If you want to use a production key you should do 3 again for the production key, add the new hash to your FB app in the developer area (see 1), sign the .apk and load it to the phone.