martinpaljak / GlobalPlatformPro

🌐 🔐 Manage applets and keys on JavaCard-s like a pro (via command line or from your Java project)
https://javacard.pro/globalplatform
GNU Lesser General Public License v3.0
673 stars 210 forks source link
cli globalplatform java javacard sdk smartcard

Build status LGPL-3.0 licensed

Latest release Maven version Maven Central

GlobalPlatformPro

     from JavaCardPro

Load and manage applets on compatible JavaCards from command line or from your Java project with a Do What I Mean approach (testimonials).

Provides an easy to use and high level interface that most of the time JustWorks(TM), is flexible and 100% open source!

Building JavaCard applets is equally pleasing with ant-javacard

Like it? Become a sponsor!

Jump to ...

Get it now!

Homebrew

brew install martinapaljak/brew/gppro --HEAD # installs the master branch

Source

Build it yourself, it is really easy:

git clone https://github.com/martinpaljak/GlobalPlatformPro
cd GlobalPlatformPro
./mvnw package

NEWS

Usage

Beware: both command line and Java API are subject to change without notice. Check back often.

Warning about correct keying

Command line samples assume default test keys of 40..4F. If you need a custom key, specify it with -key (you can give separate keyset components with -key-mac, -key-enc and -key-kek. You need to know the details or ask your card provider. Some cards require key diversification with -emv or -visa2 (ask your vendor if unsure). A Key Check Value can be given with -kcv option.

Generic information

List / install / delete applets

Please consult the help output for options that are not described here

Installation options

Lock / unlock usage

Debugging options

Usage from Java   Maven Central

Include the dependency:

<!-- https://mvnrepository.com/artifact/com.github.martinpaljak/globalplatformpro -->
<dependency>
    <groupId>com.github.martinpaljak</groupId>
    <artifactId>globalplatformpro</artifactId>
    <version>0.3.10-rc6</version>
</dependency>

Supported cards

History

The ancestor of this code is GPJ (Global Platform for SmartCardIO) which is (still) available from http://gpj.sourceforge.net. I started the project because I felt that messing with cryptic script files was not nice and I wanted to have a simple, open source, usable and native-to-the-rest-of-development-environment (Java) toolchain.

Credits (from GPJ):

Similar projects

Design principles

About

The promise of GlobalPlatformPro is similar to OpenSSL:

Why buy a smart card software kit as a black box when you can get an open one for free?

In regard to GlobalPlatform, the goal is to make simple operations like installing and removing applets and locking the card with new keys as easy as next-next-done - you don't have to know the whole Global Platform specification by heart for that or buy a piece of proprietary software for a few hundred euros! For all those features that are not described in the GlobalPlatform specification that actually make your card work... you still have to use those proprietary commands, but OpenKMS GlobalPlatformPro toolkit's flexibility (and its license) should allow you to do that as well.

License

Included/used open source projects

Contact

Legal disclaimer

The casual: trademarks to their owners, copyrights to authors, software patents to hell, legal letters to /dev/null PGP key 0x1d86f74c7b9dd593. Everything is provided AS-IS AND THERE IS A CONSTANT RISK OF DEATH FROM SUDDEN LIGHTNING. Writing in all caps made it look like serious, didn't it?


JavaCardPro