And*_*der 5 android sha google-api-console android-studio
我注意到 android studio 中的 gradle 视图签名报告中显示的 SHA1 编号与我最初的不同。我想可能是一年前换电脑造成的。我的游戏应用程序仍然能够访问排行榜和成就。当我看到我的 Google API 仪表板时,我注意到“OAuth 客户端”有我的旧 SHA1。它不允许我将其更改为新的 SHA1,并说它“已被该客户端或另一个客户端使用”,尽管我没有其他客户端。神秘的“Anroid 客户端 1”和“Android 客户端 2”既没有旧的也没有新的 SHA1。在“OAuth 客户端”下面是“OAuth 客户端(由 google 服务自动创建)”,其中包含我的新 SHA1。我继续删除了那个,尽管它警告我它在上周已被使用了 147 次(我想这是我即将衰老的证据)。看来我必须删除它才能释放不是自动创建的“OAuth 客户端”的号码。
现在看来我完蛋了,因为当我尝试更改 SHA1 时,它仍然给我“已在使用的消息”,并且我的游戏应用程序根本无法再访问 Google Play 服务。我想我应该删除“OAuth 客户端”。我能从中恢复吗?随着时间的推移它会释放吗?另一篇文章建议 7 天删除客户端,尽管我没有看到删除整个客户端的按钮,并且担心同一页面上的 API 代码被删除。
编辑 3/30 - 看起来我可能已经永久丢失了这个数字,尽管(我希望)它只影响我的排行榜和成就,而不影响 Firebase、应用内购买或广告。无论如何,我可以在 Firebase 中推出自己的排行榜和成就。具有不同包名称的新项目在 Gradle 签名报告中为我提供了相同的无法使用的 SHA1。
我终于通过电子邮件收到了 Google 支持人员的有用回复,其中仅提供了有关如何开始恢复过程的线索:
\n\nI understand you're receiving a Client ID error when trying to link your app to a Game Services project. This error message is displayed because your package ID and SHA1 are already in use by another Client ID.\n\nTo resolve this issue, please use the steps below to delete the Client ID from your Google Developers Console (formerly Cloud Console).\n\nImportant: Do not delete the Google Developers Console project before deleting the Client ID. If you\xe2\x80\x99ve already deleted the project, you will need to undelete it from your Projects list.\n\n1. Use the following URL to access the project - https://console.developers.google.com/project/186639667931\n2. Select APIs & auth > Credentials\n3. Under \xe2\x80\x9cClient ID for Android application\xe2\x80\x9d click the \xe2\x80\x9cDelete\xe2\x80\x9d button.\n4. Try linking your app in the Play Console again. If you\xe2\x80\x99re unable to view or undelete the project linked in step 1, please try accessing it while logged in with the primary email address on your Play developer account.\nRun Code Online (Sandbox Code Playgroud)\n\n没有“Android应用程序的客户端ID”,但“OAuth 2.0客户端ID”下有一个“OAuth客户端”,所以我删除了它。那仍然有一个旧的 SHA1 号码,因为它不会使用我当前的号码。所以我并没有真正删除我当前号码的某些内容,但删除它会删除整个客户端并显示一个空白屏幕。这里有一个陷阱。我将当前的 SHA1 编号添加到该屏幕,它接受了。现在,我可以从我的应用程序中再次获得 Google Play 网站的响应,尽管其响应始终是“无法访问服务”。
\n\n事实证明,这个屏幕是默认屏幕,即“Google Play Android Developer”。我需要花一段时间研究一下这是什么,但我需要添加 SHA1 的是我的实际应用程序名称。我最终发现埋在最顶部的下拉列表中,在“Google API”旁边,在我下载的示例应用程序和“Google Play Android Developer”之间。我仍然无法将当前的 SHA1 添加到其中,直到我返回并从“Google Play Android Developer”中删除“OAuth Client”。这又买回了相同的默认屏幕,所以我回到下拉列表,选择我的应用程序名称,然后最终能够将我当前的 SHA1 添加回其中。
\n\n因此,删除 SHA1 似乎并不是从 Play 服务中永久流放,而只是重新建立它的棘手过程的开始。
\n| 归档时间: |
|
| 查看次数: |
6871 次 |
| 最近记录: |