简体   繁体   English

更改 JavaCard 的 ATR

[英]Changing A JavaCard's ATR

I am researching uses for Javacards and smartcards utilizing different ATRs.我正在研究利用不同 ATR 的 Javacard 和智能卡的用途。 I want to change these card's ATRs via python to be different from the OEM ATR that comes on these cards as default.我想通过 python 将这些卡的 ATR 更改为与这些卡上默认提供的 OEM ATR 不同。 I figured out a way to change the card's atr, however, it is utilizing a script online - which really doesn't help.我想出了一种方法来更改卡的 atr,但是,它正在使用在线脚本 - 这真的没有帮助。

Below is the script I found to change the ATR using PyResMan script mode, however, it is only set to one atr, which is a bank and I have no use for it.下面是我找到的使用 PyResMan 脚本模式更改 ATR 的脚本,但是,它只设置为一个 atr,这是一家银行,我没有用它。

The Script I found Online: { ( Beginning numbers show line numbers )我在网上找到的脚本:{(起始数字显示行号

  1. 00A4040010******************************** 00A4040010************************************

  2. 00F00000 00F00000

  3. C0D6029A02F807 C0D6029A02F807

  4. C0D601240108 C0D601240108

  5. C0D601470108 C0D601470108

  6. C0D601260403600000 C0D601260403600000

  7. C0D601490403600000 C0D601490403600000

  8. C0D6012201FE C0D6012201FE

  9. C0D601360E0D80318065B0893501F183009000 C0D601360E0D80318065B0893501F183009000

  10. C0D601590E0D80318065B0893501F183009000 C0D601590E0D80318065B0893501F183009000

  11. C0D603010101 C0D603010101

  12. C0D6030510404142434445464748494A4B4C4D4E4F C0D6030510404142434445464748494A4B4C4D4E4F

  13. C0D6031d0101 C0D6031d0101

  14. C0D6032110404142434445464748494A4B4C4D4E4F C0D6032110404142434445464748494A4B4C4D4E4F

  15. C0D603390101 C0D603390101

  16. C0D6033D10404142434445464748494A4B4C4D4E4F C0D6033D10404142434445464748494A4B4C4D4E4F

} }

The problem with this script is that I only know what the first 2 lines do, and that lines 9&10 are the lines that actually contain the data for the ATR changing process.这个脚本的问题是我只知道前 2 行是做什么的,而第 9 行和第 10 行是实际包含 ATR 更改过程的数据的行。 I need to know how I can change the ATR using the ATR in regular expression form.我需要知道如何使用正则表达式形式的 ATR 更改 ATR。

If anyone knows a way to decode this script, and be able to edit it, or knows an easier way to change the ATR of an Unfused or non pre-presonialized javacard, please let me know!如果有人知道解码此脚本并能够对其进行编辑的方法,或者知道更改未融合或非预预音化 javacard 的 ATR 的更简单方法,请告诉我! I've been researching those for over a month now, and cannot find an answer that actually works.我已经研究了一个多月了,但找不到真正有效的答案。

Setting the ATR for a smartcard is not primarily the domain of Javacard specification.为智能卡设置 ATR 主要不是 Javacard 规范的领域。 Today there is no generic specification or method to set the ATR for all smartcards, as there is no universal way to initialize or personalize the smartcard itself and this is mostly vendor specific.今天没有通用的规范或方法来为所有智能卡设置 ATR,因为没有通用的方法来初始化或个性化智能卡本身,这主要是特定于供应商的。

The script that you found online belongs to an NXP Javacard, this information is not standardized and is also not intended for public use to my knowledge, therefore is removed some sensible information.您在网上找到的脚本属于 NXP Javacard,此信息不规范,据我所知也不供公众使用,因此删除了一些敏感信息。 Please contact your card vendor to get information on how to change the ATR(it might not be possible or easy).请联系您的卡供应商以获取有关如何更改 ATR 的信息(这可能不太可能或不容易)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM