基于主机卡仿真与固定卡ID [英] Host-based Card Emulation with Fixed Card ID

查看:392
本文介绍了基于主机卡仿真与固定卡ID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Android 4.4系统的推出了基于主机卡仿真(HCE)。如你所知,所有的NFC卡配备了一个固定的卡ID( NfcAdapter.EXTRA_ID )。

Android 4.4 introduced Host-based Card Emulation (HCE). As you know, all NFC cards come with a fixed card ID (NfcAdapter.EXTRA_ID).

我的办公室的门进入,通常检测到NFC卡的ID为授权。闪烁我的手机奇巧后,我试图扫描我的手机与门禁读卡器。但每当屏幕关闭并再次,我得到一个不同的卡ID。

My office door access usually detects the NFC card ID for the authorization. After flashing my phone to KitKat, I tried to scan my phone with the access reader. But whenever the screen turns off and on again, I get a different card ID.

我也尝试保持在手机屏幕上,并注册模拟卡ID的门禁系统。它成功地授予访问权限开门。但是,这是行不通的屏幕会关闭并重新之后。

I did try keeping the phone screen on, and registering the emulated card ID to the door access system. It managed to grant the access to open the door. But this won't work after the screen turns off and on again.

自从奇巧推出HCE模式,我一直在试图用我的电话效仿我的门禁卡。

Ever since KitKat introduced HCE mode, I have been trying to emulate my door access card using my phone.

任何想法使得手机仿真卡ID固定的吗?

Any ideas for making the phone emulated card ID fixed?

推荐答案

这是(至少官方API)不可能的:

This is (at least with the official API) not possible:

在交换HCE设备将present它的UID的第一部分; HCE设备应当被假定为具有随机的UID。这意味着,在每一个抽头,该UID是psented向读者将是一个随机产生的UID $ P $。正因为如此,NFC读取器不应该依赖于HCE设备的UID作为认证或识别的一种形式。

In the first part of the exchange the HCE device will present its UID; HCE devices should be assumed to have a random UID. This means that on every tap, the UID that is presented to the reader will be a randomly generated UID. Because of this, NFC readers should not depend on the UID of HCE devices as a form of authentication or identification.

(<一href="http://developer.android.com/guide/topics/connectivity/nfc/hce.html#ProtocolParams">http://developer.android.com/guide/topics/connectivity/nfc/hce.html#ProtocolParams)

这篇关于基于主机卡仿真与固定卡ID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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