简体   繁体   中英

JavaCard store (Secret) Data

Setup: NXP SmartCard with JavaCard 2.2.2

I want to store a wrapped keypart and a pem File on a smartcard in a secret manner. But I am wondering if it's possible to store this kind of files or at least their binary Data as bytestreams. I found the FileSystem Class in an old document but that seems to be gone in JavaCard 2.2.2. Is there any possibility to store data in a safe manner?

Keys and other sensitive data should always be stored in either Java Card Key objects or PIN objects. The operating system ensures the best integrity of this kind of secret data. Keys should never be stored in plain byte arrays.

PEM is just a format. If it represents a key store it in a Key object; if it represents a certificate, you can store it in a plain byte array. Certificate data is not sensitive.

There is no filesystem implementation in the Java Card runtime; you have to build your own.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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