Android Facebook SDK: Key hash does not match
来源:互联网 发布:攻城掠地数据库 编辑:程序博客网 时间:2024/05/17 20:54
开发一个Android App,其中使用了Facebook SDK,需要向Facebook提交该App的key hash。
按照Facebook官方步骤,使用以下命令即可生成key hash:
keytool -exportcert -alias <RELEASE_KEY_ALIAS> -keystore <RELEASE_KEY_PATH> | openssl sha1 -binary | openssl base64
然而,App一直未能正确运行,很简单的一个App,各种因素干扰,找了很久原因,终于确认是key hash不匹配的问题,然而,为什么呢,一切操作皆遵守官方,已经试了几百遍了!Fuck openssl! A big waste of time!
问题便出在openssl上,openssl较新的版本09.8k存在bug,其计算得出的key hash可能是错误的,我们回滚到0.9.8e版本,问题得以解决。so,用开源的东西有时候是有代价的。
以下是国外的受害者:
fernandomatos commented on 12 Nov 2011
buhlly88 commented on 26 Nov 2011
fernandomatos,
Just wanted to say thank you. I spend 2 days banging my head against the wall until I finally came across this post. Once I used the older version of openssl to generate the security hash it worked.
Thanks for posting.
kotibabu commented on 23 Jul 2012
thank you from past 3 days i spent time with this through you post my issue is solved
chaunvbka commented 25 days ago
thanks you very much. I also lost a lot of time with this problem.
0 0
- Android Facebook SDK: Key hash does not match
- facebook key hash生成
- Android开发之获取Facebook应用的key hash
- FaceBook invalid key hash问题
- Android集成Facebook sdk,Key Hashes生成步骤
- Android SDK/Android.bat does not find SWT.jar file
- 【Android】Facebook 登陆APP ID获取 android hash key获取,development/ release
- Android sdk:ERROR: SWT folder '' does not exist.问题
- Does not match the target endianness问题
- signer information does not match问题解决
- H-JTAG:flash id does not match
- metadata file does not match checksum
- Metadata file does not match checksum问题解决
- Requested rate does not match actual rate
- literal does not match format string 解决办法
- request does not match component version
- The frontend does not match Zabbix database
- Number of responses does not match queries
- swust oj 2516 教练我想学算术 dp+组合计数
- 终端命令记录
- c++ bind functional
- 面向对象的特征有哪些方面?
- 3Sum Closest
- Android Facebook SDK: Key hash does not match
- Qt之QTableWidget的使用及常用设置
- java有没有goto
- vc助手的安装
- 基于HT for Web矢量实现HTML5文件上传进度条
- int 和 Integer 有什么区别?
- ios framework 使用注意事项
- org.hibernate.HibernateException: No TransactionManagerLookup specified
- 使用VS2013为基于对话框的程序加SplashView
Hi guys,
Windows users have to be careful about openssl-for-windows (http://code.google.com/p/openssl-for-windows/downloads/list), the latest version, at least on plataform 64bits, don't generate the correct hash that Facebook need it for android apps.
When we are using this plugin we need provide a security hash to the facebook, in our aplication page (https://developers.facebook.com/apps), if what i'm saying don't make sense for you I recomend you read these materials:
http://developers.facebook.com/docs/mobile/android/build/#sig
http://developer.android.com/guide/publishing/app-signing.html
If you've read these materials and already know how works and how you will have to do to generate your security hash to use this plugin, remember of this tip:
Use one of this versions: openssl-0.9.8e_X64.zip or openssl-0.9.8d_X64.rar
You should not use the openssl-0.9.8k_X64.zip.
I hope this tip be useful. I lost a lot of time, testing ways to generate the correct hash and in the end the problem was with the latest version of openssl.