Android Google登录失败,错误代码为8(无消息) [英] Android Google Sign In fails with error code 8 (no message)

查看:919
本文介绍了Android Google登录失败,错误代码为8(无消息)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将Google Sign In集成到我的应用程序中,但是出现一些我无法理解的错误.

I am trying to integrate Google Sign in to my application, but I get errors that I cannot understand.

我已经按照此处的教程进行了所有配置,但可以不认证我.向我展示了显示我的帐户的登录面板,并触发了登录活动OnActivityResult,当查看GoogleSignInResult时,我有一个

I have configured everything according to the tutorial here, but it would not authenticate me. I am presented with the login panel that shows my accounts, and the login activity OnActivityResult fires, when looking into the GoogleSignInResult, I have a Status with a statusCode 8 and no message.

它似乎与

It seems to be related to this, but it is a bit confusing.

有什么主意吗?

推荐答案

查看以下问题的答案: An INTERNAL_ERROR( 8)发生在Android上来自GoogleSignInOptions的requestEmail

Check out the answer to this question: An INTERNAL_ERROR (8) occurred when requestEmail from GoogleSignInOptions on Android

如果您收到错误代码8(INTERNAL_ERROR),请在开发控制台中再次检查您的应用注册.请注意,每个已注册的Android客户端均由(包名称,Android签名证书SHA-1)对唯一标识.如果您在调试和生产环境中具有多个程序包名称/签名证书,请确保注册它们中的每对.要验证:

If you get error code 8 (INTERNAL_ERROR), please double check your app registration in dev console. Note that every registered Android client is uniquely identified by the (package name, Android Signing Certificate SHA-1) pair. If you have multiple package names / signing certificate for your debug and production environments, make sure to register every pair of them. To verify:

  1. 打开凭据"页面,然后选择您的项目
  2. >
  3. 确保每对都有一个 Android 类型的OAuth 2.0客户端ID. 要为您的Android客户端创建新的OAuth 2.0客户端ID,请从下拉列表中选择 New Credentials -> OAuth2 Client ID ,选择Android并输入您的包名称/签名证书那里的指纹.
  1. Open the Credentials page and select your project
  2. Make sure every pair has an Android typed OAuth 2.0 client IDs. To create a new OAuth 2.0 client ID for your Android client, select New Credentials->OAuth2 Client ID from the dropdown, select Android and input your Package name / Signing-certificate fingerprint there.

要获取签名密钥证书SHA-1:

To get your signing key certificate SHA-1:

标准调试键 keytool -list -v -keystore ~/.android/debug.keystore -alias androiddebugkey -storepass android -keypass android

Standard Debug Key keytool -list -v -keystore ~/.android/debug.keystore -alias androiddebugkey -storepass android -keypass android

其他(自定义)键 keytool -list -v -keystore $YOUR_KEYSTORE_LOCATION

Other (Custom) Key keytool -list -v -keystore $YOUR_KEYSTORE_LOCATION

这篇关于Android Google登录失败,错误代码为8(无消息)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆