Android应用的“密钥哈希"与任何存储的密钥哈希都不匹配 [英] Android app Key Hash doesn't match any stored key hashes

查看:177
本文介绍了Android应用的“密钥哈希"与任何存储的密钥哈希都不匹配的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Play商店的生产环境中有一个应用程序,该应用程序使用Facebook SDK登录. 当我从Eclipse调试应用程序时,没有问题,但是在Facebook上向我询问权限后,在生产环境中出现以下错误. 我在developer.facebook.com的应用程序页面上添加了使用以下命令使用keytool生成的密钥哈希:

I have an application on production on Play Store which uses a login with the Facebook SDK. When I debug the application from Eclipse there is no problem, but when its on production it gives me the following error after Facebook asks me for the permissions. I have added on my app page on developers.facebook.com the key hash generated with keytool using this command:

keytool -exportcert -alias diego -keystore "C:\ Users \ Diego \ Desktop \ CeluChat.KeyStore" | "C:\ openssl \ bin \ openssl.exe" sha1 -binary | "C:\ openssl \ bin \ openssl.exe" base64

keytool -exportcert -alias diego -keystore "C:\Users\Diego\Desktop\CeluChat.KeyStore" | "C:\openssl\bin\openssl.exe" sha1 -binary | "C:\openssl\bin\openssl.exe" base64

CeluChat.KeyStore是我导出已签名应用程序时使用的密钥库,并且当keytool向我提示输入密码时,我在导出时输入了相同的密码.

CeluChat.KeyStore is the keystore I used when I exported the signed application, and when keytool promts me for the password, I entered the same when exported.

但是使我投入生产的错误(从Play商店下载)是:

But the error that gives me on production (downloaded from Play Store) is:

10-20 22:21:10.752:W/fb4a(:):BlueServiceQueue(5872): com.facebook.http.protocol.ApiException:密钥哈希 VQ3XhZb5_tBH9oGe2WW32DDdNS0与任何存储的密钥哈希都不匹配.

10-20 22:21:10.752: W/fb4a(:):BlueServiceQueue(5872): com.facebook.http.protocol.ApiException: Key hash VQ3XhZb5_tBH9oGe2WW32DDdNS0 does not match any stored key hashes.

例外情况下的密钥哈希值与使用keytool生成的密钥哈希值不同.无论如何,我在Facebook上添加了密钥哈希,但仍然无法正常工作.

The Key Hash that is on the exception is different from the key hash generated with keytool. Anyway I added the Key Hash on Facebook, but it is still not working.

推荐答案

Facebook一些如何用_

Facebook some how replaces +,- and / with _

因此,只需尝试用+,-和/替换_并添加该哈希键.

So just try replacing _ with +, - and / and add that hash-key.

希望它应该能工作.

这篇关于Android应用的“密钥哈希"与任何存储的密钥哈希都不匹配的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆