Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to use keytool and OpenSSL for Facebook Android SDK installation

I'm trying to create a Facebook integrated Android app, but trying to use Facebook's Android SDK is tiring. Here's the tutorial I'm following.

I'm stuck on the step Using the Keytool. I've searched around a bit and apparently I have to install OpenSSL which I promptly did.

I found keytool under these directories on my Windows machine:

C:\Program Files\Java\jdk1.6.0_25
C:\Program Files\Java\jdk1.7.0

When I run

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

I get the following error:

openssl:Error: 'keytool' is an invalid command.
like image 455
ask Avatar asked Dec 21 '22 20:12

ask


1 Answers

I followed Maulik J's post from the link provided by Venky here and tried this command in the command prompt and it worked:

C:\Program Files\Java\jdk1.7.0\bin>keytool -export -alias androiddebugkey -keystore "C:\Users\MyUser\.android\debug.keystore" | C:\Users\MyUser\Downloads\openssl-0.9.8k_X64\bin\openssl.exe sha1 -binary | C:\Users\MyUser\Downloads\openssl-0.9.8k_X64\bin\openssl.exe enc -a -e
like image 170
ask Avatar answered Apr 27 '23 19:04

ask