Skip to content
This is a tool to connect web pages to smart card via java script. This tool works with all ISO7816/14443 and NFC smart cards.
JavaScript Java HTML CSS
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.vscode
build
jcardsimsample
public
smartcardBridge
src
.gitignore
README.md
package-lock.json
package.json

README.md

smartcardPage

This is a tool to connect web pages to smart card via java script. This tool works with all ISO7816/14443 and NFC smart cards. smartcardPage is a demo page to demonstrate how to use smartcardBridge. You can send APDU command and receive APDU response to/from all ISO7816/14443 and NFC smart card with this utility. It also supports jCardSim as java card simulator with a simple REST server. You may use smartcardBridge to share smart card between different virtual machines (VM) and to share a smart card on a network.

Online Demo

You can see the online demo version of smartcardPage and smartcardBridge at: https://hosseinpro.github.io/smartcardPage/

Download Binary

You may download smartcardBridge setup file for Windows and MacOS here

Description

smartcardPage uses smartcardBridge and calls its HTTP services. To do that, smartcardPage includes a specific JavaScript library smartcardBridgeClient.js which implements all required calls and catches. If you would like to use smartcardBridge at your own web page, you just need this library. Although, you may develop your own library and call smartcardBridge services directly.

These are smartcardBridgeClient.js functions which are implemented as JavaScript Promise and you can find their sample codes in smartcardPage source code.

  • getVersion : Connects to smartcardBridge and returns its version. You may use this function to check if smartcardBridge is installed.
  • listCardreaders : Returns a list of all smartcard readers which are connected to the client.
  • cardreaderConnect : Connects to a smartcard inserted in a smartcard reader.
  • cardreaderDisconnect : Disconnects from a smartcard.
  • cardreaderTransmit : Sends a smartcard command (APDU) to a smartcard and receives its response.

Compile and Run

smartcardPage is developed using ReactJS and Bootstrap 4. It also uses Axios as HTTP client library to call smartcardBridge HTTP services. Actually, smartcardBridge and smartcardPage are two separate independent projects which you may download each one and compile them independently.

To compile smartcardPage, you must install NPM or another package manager, and run these commands:

  1. Download smartcardPage's source code with:
    git clone https://github.com/hosseinpro/smartcardPage
  1. Go to smartcardPage folder and install required node modules with:
    npm install (or equivalent command in yarn or other package managers)
  1. Run development server to display smartcardPage:
    npm start

Change of address

smartcardBridge serves at http://localhost:3333 by default. If you want to change that, you can update the service address for smartcardPage at /src/App.js in 'smartcardBridgeAddress' properties of MainPage component.

You can’t perform that action at this time.