How to get a hash signature for facebook from a pair of public private keys?

I am using the signapk version for one of my projects. I sign my apk with an open, private key pair (.pk8 and .pem).

My application uses facebook's single-sign-on mechanism, and I need a hash of the signing certificate registered with facebook to make sure the correct application launches the single sign-on process. Facebook provides the following code example to generate this hash:

keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore 
| openssl sha1 -binary
| openssl base64

I am a little confused about how to create an appropriate hash from my public key, a private key pair that I use for signing.

+3
source share
3 answers

APK, PK8 + PEM. () APK

  • *.apk

    • apk META-INF\CERT.RSA
    • :

          keytool -printcert -file CERT.RSA
      

      sha1

  • sha1.bin sha1 ( )

  • :

    openssl base64 -in sha1.bin -out base64.txt
    

base64.txt APK FB KeyHash

+4

Facebook base64- SHA1.

sha1 , .pem!..

SHA1 .pem: - openssl x509 -fingerprint -in Certificate.pem -noout

SHA1 .pem, certicicate.pem .pem!...

SHA1 - SHA1 base64, , :

http://tomeko.net/online_tools/hex_to_base64.php?lang=en

, SHA1, base64, HASH Facebook!..

0

Download Open SSl and install on your computer .. Check this out, I asked this question some answers for Question ..

-1
source

All Articles