How to create key hash in Windows 7 64bit
Recently i tried to get started with Facebook SDK for Android . Actually there is a good tutorials for getting started in facebook developer site. I followed this link
https://developers.facebook.com/docs/getting-started/facebook-sdk-for-android/3.0/
I created a sample app in Facebook developer site and added the key hash in App setting . but When started the app i found the Facebook Authentication is working at all.I got
If you press okay it will go back to the application. And it will show an error like
This is because you have entered a wrong key in Apps settings in https://developers.facebook.com/apps.
After lot of googling i found that the keytool am using giving a wrong key hash. The error is caused by Openssl-for- windows library. Actually i downloaded the latest openssl-for-windows library from Google code. After more searching i found the latest library won't work fine in 64 bit windows. I will list out what i have done.
https://developers.facebook.com/docs/getting-started/facebook-sdk-for-android/3.0/
I created a sample app in Facebook developer site and added the key hash in App setting . but When started the app i found the Facebook Authentication is working at all.I got
Mobiletest is misconfigured for Facebook login. Press okay to go back to the application without connecting to facebook
If you press okay it will go back to the application. And it will show an error like
Login Failed: invalid_key: android key mismatch. Your key "abcdefghijklmns" Does not match tje allowed keys specified in your application Settings
This is because you have entered a wrong key in Apps settings in https://developers.facebook.com/apps.
After lot of googling i found that the keytool am using giving a wrong key hash. The error is caused by Openssl-for- windows library. Actually i downloaded the latest openssl-for-windows library from Google code. After more searching i found the latest library won't work fine in 64 bit windows. I will list out what i have done.
- First download openssl-0.9.8e_X64 (Note it's not the latest version. The latest version when am writing is openssl-0.9.8k_X64).
- Extract it . You will found libeay32.dll, ssleay32.dll and openssl.exe in bin folder. Copy it to C:\Windows\SysWOW64 (If it's added to path or Extract it somewhere and give the full path in command).
- Use this comand
- use the password android
- Copy and paste the 30 character key hash in Facebook
keytool -exportcert -alias androiddebugkey -keystore %HOMEPATH%\.android\debug.keystore | openssl sha1 -binary | openssl base64
Now it's works fine for me.
Comments
Duplication
BluRay Disc Duplication