未通过Smart Lock API在应用中检索关联网站的密码 [英] Password from associated website not retrieved in app via Smart Lock API

查看:126
本文介绍了未通过Smart Lock API在应用中检索关联网站的密码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

将我的https网站和应用关联到共享存储的凭据并收到确认该关联是实时的,但是当我在我的应用程序中调用 CredentialsApi.request()方法时,我无法检索我的网站使用Chrome密码管理器保存的任何凭据。如何解决这个问题?

解决方案

将数据提交到将您的应用与 https 网站相关联, ,这里有一些要检查的内容:如果您刚刚保存了新的凭证,请等待几分钟以便Chrome和Android之间进行同步,然后再点击


  • 和设备

  • 尝试真正的设备(Android 4+)而不是模拟器,确保设备运行最新版本的Google Play服务(8+)并且具有活动的Internet连接

  • 确保您使用与Android设备相同的帐户登录Chrome,并且帐户处于良好状态(不需要密码重新输入并符合任何公司政策要求,例如同步并接收推送电子邮件通知,例如e) 如果关联最近刚刚启用,并且您在设备上的应用程序中测试了API集成,请访问 passwords.google.com 并删除您的网站/应用程序的任何现有条目,以强制删除任何缓存数据

  • 访问您的Chrome浏览器中的网站,按正常方式登录并在出现提示时保存密码,确认密码已保存并显示在chrome:// settings / passwords和 passwords.google.com 在您的关联中指定的https域下(如果将鼠标悬停在用户界面中显示的域上,则完全可见)

  • 通话Android上的API使用与您的提交相匹配的软件包名称的apk并使用与您的Play商店应用程序相同的密钥存储库进行签名,请记住,如果您处于非释放密钥或哟的开发环境中,调试密钥库可能会有所不同请注意,如果有多个凭据可用,则API回调可能不会立即成功,因为您可能需要处理多个存储凭证并调用UI以允许用户选择如果您在应用中保存凭证,Chrome会提供自动填写网页表单的功能关联后的https网站在大约24小时内连续运行(并且凭据也可通过 Chrome Credentials API )。如果您正在寻找测试Smart Lock集成的完整指南,请查看这篇文章


    I've associated my https website and app to share stored credentials and received confirmation that the association is live, but when I call the CredentialsApi.request() method in my app, I am not able to retrieve any credentials from my website that were saved with the Chrome password manager. How can I fix this?

    解决方案

    After submitting the data to associate your app and https website, and receiving confirmation that the association is live, here are some things to check:

    • if you've just saved a new credential, wait a couple minutes for synchronization between Chrome and Android and across devices
    • try a real device (Android 4+) and not an emulator, ensure that the device is running the latest version of Google Play Services (8+) and has an active internet connection
    • ensure that you are signed in to Chrome with the same account as your Android device, and that the account is in good state (doesn't require password re-entry and meets any corp policy requirements, e.g. is in sync and receives push email notifications, for example)
    • if the association just went live recently and you were testing the API integration in the app on your device before it was enabled, visit passwords.google.com and delete any existing entries for your website / app to force removal of any cached data
    • visit your website in Chrome, sign in as normal and save your password when prompted, confirm that the password was saved and appears in chrome://settings/passwords and passwords.google.com under the https domain specified in your association (fully visible if you mouse over the domain shown in the UI)
    • call the API on Android using an apk with package name matching your submission and signed with the same keystore as your Play Store app, keep in mind that the debug keystore may be different if you are in a development environment with non-release keys or you move to another computer.

    • note that if there are multiple credentials available, the API callback may not immediately be success as you might need to handle multiple stored credentials and invoke UI to allow the user to select a credential

    Note that if you save a credential in the app, Chrome will offer to auto-fill in web forms on associated https websites after the association has been live for about 24 hours (and the credential will also be available via the Chrome Credentials API). If you're looking for a complete guide to testing a Smart Lock integration, check out this post.

    这篇关于未通过Smart Lock API在应用中检索关联网站的密码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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