在 Ajax Adob​​e AIR 应用程序中与 API 共享秘密 [英] Shared secret with API in an Ajax Adobe AIR app

查看:21
本文介绍了在 Ajax Adob​​e AIR 应用程序中与 API 共享秘密的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对开发 AIR 应用程序还很陌生,所以也许这是一个愚蠢的问题,但我似乎无法从谷歌找到任何答案.非常感谢您能给我的任何帮助.

I'm pretty new to developing AIR apps, so maybe this is a dumb question, but I can't seem to find any answers from google. Any help you can give me is greatly appreciated.

我正在使用 Ajax 构建一个 AIR 应用程序,该应用程序与 flickr 的 Api 相同,具有共享密钥.问题是air安装包包含所有源码,我不想泄露我的共享秘密.有没有办法做到这一点?我可以隐藏一些来源,或者以某种方式将这个共享秘密包含在应用程序中而不泄露它吗?

I'm building an AIR app with Ajax using an api that is identical to flickr's Api, with a shared secret key. The problem is that the air installation package contains all the source and I don't want to give away my shared secret. Is there any way to do this? Can I hide some source, or somehow include this shared secret within the app without giving it away?

感谢您的帮助.

推荐答案

您可能想要使用 EncryptedLocalStore 以安全地存储您的 API 密钥.

You may want to use EncryptedLocalStore to securely store you API key.

但是,您将无法将它与应用程序一起分发,因为商店的加密取决于应用程序在哪个操作系统上运行.

But, you won't be able to distribute it with the application as the store's encryption depends of which OS the application is running on.

在应用程序安装时为商店设置种子的方法是:

A method to seed the store would be, on app's install:

  1. 运行安装程序
  2. 根据需要运行安装后脚本.
  3. 检查商店.如果没有密钥,请从您的网站下载密钥并将其存储在 ELS 中.

使用这种方法,用户永远不会知道您的密钥,但它会出现在应用商店中.

Using this method, the user will never know your key but it will be present in app's store.

这篇关于在 Ajax Adob​​e AIR 应用程序中与 API 共享秘密的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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