18
Views
2
Comments
Solved
[Social Login Mobile] Social Mobile plugin on Android doesn't work with Google
Question
social-login-mobile
Mobile icon
Forge asset by OutSystems
Application Type
Mobile

Hello,

We have been using the Social Mobile plugin on iOS and we got it to work there so we are able to log in with a Google Account. However, on the Android side, we are having trouble getting it to work. We are getting the 101 status code back, which corresponds to "The login was cancelled". We have been trying things, but no success. 

The main question is, how to set up the process for Android. I have been doing some research online and I found some potential problems which I wanted to check here if my assumptions are correct. I found that login with Google through Android and login with Google through iOS need separate ClientId's. Is that indeed the case? And then depending on the request being done on Android or iOS, use the ClientId for the specific OS? 

Then my second question is based on the first question. If you need to make a separate ClientId, you need to do that in the Google console. Is it correct that to make the ClientId for Android, you need to have the SHA-1 Certificate Fingerprint? And if that is the case, how do you get this? 

Help would be greatly appreciated, thanks in advance!

Best regards,

Tyler


2021-04-12 11-47-04
Bart Nooijens
Solution

Hi Tyler,

I believe most of your assumptions are correct. The component's design is somewhat ambiguous, in my opinion.

I tested this component a while ago and in my test I did not provide a ClientId in the code (as you can see in the image below). And still, the Google login was working. Though, I did configure the Social Login Configurator and created all needed Client Id's in the Google API Console.

To obtain the fingerprint, Java must be installed on your computer. It is likely located in the following directory: C:\Program Files\Java\jre-1.8\bin. Use the command prompt to navigate to that location and execute the following command:

"keytool -keystore path-to-debug-or-production-keystore -list -v"

Hope this helps you in a way.

Best regards,

Bart

2019-09-09 12-23-19
Tyler Cools

Hi @Bart Nooijens,

Thanks for the answers, this was indeed the trick, combining it with the correct configuration in the Google API console.

Thanks! :)

Best regards,

Tyler

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.