問(wèn)題描述
我只是想要一些確認(rèn).
我在 windows 上開(kāi)發(fā)
I'm developing on windows
我正在嘗試將 facebook 集成到應(yīng)用程序中,但 SDK 文檔說(shuō)我需要導(dǎo)出簽名"
I'm attempting to integrate facebook into an app and the SDK documentation says I need to 'export a signature'
從這里:http://developers.facebook.com/docs/guides/手機(jī)/#android
所以它說(shuō)運(yùn)行這個(gè)命令:
So it says run this command:
keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore | openssl sha1 -binary | openssl base64
首先我必須下載 openssl:OpenSSL
First I had to download openssl: OpenSSL
現(xiàn)在上面的命令,我假設(shè)應(yīng)該轉(zhuǎn)換為:
Now the command above, I assume should be converted to:
"C:path ojavakeytool" -exportcert -alias your_alias -keystore "C:path oyourkeystorekeystore.name" | "C:path oopenssl_installinopenssl" sha1 -binary |"C:path oopenssl_installinopenssl" base64
- 所以您想要安裝在最新 Java 安裝文件夾中的 keytool?
- 您希望別名是您用于在 eclipse 中正常創(chuàng)建 apk 的別名的名稱(chēng)嗎?
- 您希望密鑰庫(kù)成為您在導(dǎo)出 Android 應(yīng)用程序時(shí)使用的那個(gè)?
- 您希望 openssl 成為您剛剛安裝的那個(gè)
因此,一旦我完成此操作,它就會(huì)要求輸入密碼:(它會(huì)在我輸入密碼時(shí)顯示密碼)
So once I've done this it asks for a password: (it shows the password as I'm typing it)
如果我輸入正確的密碼,我會(huì)得到
If I enter a correct password I get
'zR2tey1h9kqPRSW/yEYEr0ruswyD='(改為公開(kāi))
'zR2tey1h9kqPRSW/yEYEr0ruswyD=' (changed for public)
但是如果我輸入了錯(cuò)誤的密碼,它仍然會(huì)以
but if I enter an incorrect password it still returns me a code in the form of
'ga0RGNYHvTR5d3SVDEfpQQAPGJ1='?
'ga0RGNYHvTR5d3SVDEfpQQAPGJ1='?
所以是的,我只是在尋找我做正確事情的確認(rèn),這是預(yù)期的輸出
So yeah, was just looking for a confirmation that I'm doing the right thing, and this is the output expected
推薦答案
是的,我認(rèn)為你的做法是正確的.我也執(zhí)行此命令并將此哈希放入我的 fb 應(yīng)用程序中,并且它可以正常工作.
yes you are doing it in a right way i think.i also execute this command and put this hash in my fb app and its works properly.
這篇關(guān)于帶有 Android Facebook SDK 的 keytool的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!