0

I am using the latest version of Unity. I am trying to integrate the latest version of Facebook SDK into my app. In the Unity editor where facebook settings are displayed, I get an error saying that my keystore file is missing.

Screenshot

I have Openssl installed and added to environment variables. I have JDK 1.8 installed and added to environment variables. I have JRE 1.8 installed and added to environment variables.

Obviously, I have a keyfile that I have generated using Unity. Please help me in what I am doing wrong. There was one similar discussion, but the original question was different. That's why I posted this here. Also the answers there are outdated as it was 4 years old.

Abhilash K Abhi
  • 5
  • 1
  • 2
  • 3

2 Answers2

5

The facebookSDK is looking for your debug.keystore which should be present in your user folder like so:

C:\Users\userName\.android\debug.keystore

To create a new debug.keystore use the following command

keytool -genkey -v -keystore debug.keystore -storepass android -alias androiddebugkey -keypass android -keyalg RSA -keysize 2048 -validity 10000

more explainations about debug.keystore here: What is the use of debug.keystore in android? and How can I create a keystore?

BenBenMushi
  • 205
  • 2
  • 10
  • But I already have a keyfile. Is it compulsory that there should be a debug keyfile present in the PC even-though we have a keyfile? This answer atually solved my issue for now. – Abhilash K Abhi Jan 02 '18 at 12:09
  • Same goes for the openSSL error... I wasted a lot of time because of thoses errors. Eventually the facebookSDK will throw a post-build error event if your apk was built just fine. I dont remember if the warning you linked above causes the same issues, but it might be harmless anyway depending on your configuration – BenBenMushi Jan 02 '18 at 13:43
0

For anyone whos debug is produced, and is at the appropriate location but Facebook isn't detecting it. Try creating a new keystore file (you don't need to use it anywhere but just create one). By doing so you will force FB SDK to look for key forcefully.

HoloLady
  • 1,041
  • 1
  • 12
  • 28
Sandy
  • 3
  • 2