Access Smart Card Using Java

I am trying to find out how Java accesses smart cards due to project analysis. I wonder if there is any virtual smart card that I could use to conduct some tests with Java?

By the way, I read about Java Card and it looks like it is used to run Java in cards, and not to access smart card data using Java, right?

+6
java smartcard
source share
5 answers

Take a look at this tutorial + example . And. (I used these examples and they work great).

The important point is that you cannot extract anything from the smart card. You can only send things to your processor. Therefore, whenever you receive a PrivateKey object, you actually do not have a private key - it is only a proxy server for the SmartCard processor and the method that calls it calls the processor.

I do not know virtual smart cards.

Interesting javax.smartcardio API

+9
source share

There is a Java Card emulator bundled with the Java Development Development Kit . If you plan to use a real card at a certain stage, get version 2.2.1 or 2.2.2, since I would not expect any version 3 cards for a while. You still need an applet to install on the card. Java map does nothing by itself. Only when you download the map applet will it perform any useful function.

One problem with the emulator in JCDK is that you cannot use javax.smartcardio to access the card, and at the moment this is the preferred method for communicating with the card. Another popular alternative to the OpenCard Framework has not been supported for some time.

+2
source share

Here you can get a virtual smart card (and virtual reader): http://sourceforge.net/projects/vsmartcard/

+1
source share

Javacard uses Java only a subset of Java development. It is better not to use the Java development environment. Because some special effects do not support. You can download a plug-in or a dedicated development environment, you can download it here in the development environment associated with www.javacos.com.

+1
source share

If you need to emulate JavaCard, try using jCardSim: http://jcardsim.org . It also supports access through the javax.smartcardio API and apdu scripts.

0
source share

All Articles