【问题标题】:How can I securely use client_id and api key in gmail extension for chrome?如何在 chrome 的 gmail 扩展中安全地使用 client_id 和 api 密钥?
【发布时间】:2018-02-24 13:51:08
【问题描述】:

现在我已经在后台页面中硬编码了我所有的键。授权成功后生成的access_token是否需要保密?

【问题讨论】:

    标签: google-chrome-extension google-oauth gmail-api


    【解决方案1】:

    通过使用 Google OAuth,它们非常安全,除非您明确想要公开它们。此外,就像每个 chrome 扩展开发人员一样,只需 place your client_id in your manifest

    【讨论】:

    • 使用 chrome.identity.getAuthToken 检索令牌后,如何使用此令牌调用 gmail api?当我转到gmail api site for javascript 时,我看到加载客户端库脚本并使用 gapi 关键字向 api 发出请求。
    猜你喜欢
    • 1970-01-01
    • 2017-04-28
    • 2017-01-30
    • 1970-01-01
    • 2020-04-15
    • 2019-04-17
    • 2020-01-28
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多