我想在 Android 中创建一个类似谷歌钱包的应用程序。据说“所有支付凭证都存储在一个名为安全元件包含在手机中”。我如何访问它安全元件并将我的卡凭证存储到其中。
我的目标是在收银台使用我的手机 (Nexus) 而不是我的卡。
所以我想要的是将一些数据存储到安全元件芯片中,并在我点击 NFC 读取器时访问数据。
如果您检查Google 电子钱包常见问题解答 http://www.google.com/wallet/faq.html你可以找到以下内容:
Your payment credentials are stored in a chip called the Secure Element contained within your phone. The Secure Element is isolated from your phone’s main operating system and hardware. Only authorized programs like Google Wallet can access the Secure Element to initiate a transaction.
Even Google Wallet itself has very limited access to the Secure Element, and cannot read or write data from its memory. There are multiple levels of protection for data stored on the Secure Element and it is protected at the hardware level from snooping or tampering.
所以基本上...你无权访问这个SecureElement
。也许与电话制造商交谈,为您提供访问/访问方式SecureElement
将使您能够做到这一点...但我认为这超出了您的范围。
EDIT:另一种解决方案是将您的数据存储在SQLite
数据库,也可以使用encryption
在该数据库上,例如AES
...或者任何你喜欢的。您仍然需要注意如何保存/分发encryption/decryption keys
.
如果您担心有人丢失手机而“创始人”试图窃取数据,您还可以在您的手机上实施密码保护Application
如果密码连续输错3次,则删除SQLite
存储数据的数据库。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)