https://github.com/profitware/smartcard
Playing Java SmartCards with Clojure
https://github.com/profitware/smartcard
java javacard jcardsim jcop smartcard
Last synced: 10 months ago
JSON representation
Playing Java SmartCards with Clojure
- Host: GitHub
- URL: https://github.com/profitware/smartcard
- Owner: profitware
- License: mit
- Created: 2018-11-28T21:08:36.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-12-05T02:03:56.000Z (over 7 years ago)
- Last Synced: 2025-08-18T02:04:00.555Z (11 months ago)
- Topics: java, javacard, jcardsim, jcop, smartcard
- Language: Clojure
- Size: 16.6 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Smartcard
[](https://clojars.org/smartcard)
[](https://travis-ci.org/profitware/smartcard)
[](https://versions.deps.co/profitware/smartcard)
The `Smartcard` library is a simple wrapper around Java Smartcard library.
## Installation
Prerequisites include installed `pcsc-lite` and `pcsc-tools` software and `pscsd` service up and running.
To install, add the following to your project `:dependencies`:
[smartcard "0.1.3"]
Or use the [Leiningen](https://leiningen.org/) template to build a new application from scratch:
lein new smartcard my-smartcard-application
## Usage
```clj
(use 'smartcard.core)
(def applet-id [0x4f 0x46 0x46 0x5a 0x4f 0x4e 0x45 0x32 0x10 0x01])
(defsmartcard applet-function applet-id
(let [line (->> (.transmit card [0x10 0x30 0x00 0x00 0x00])
.getData
bytes-to-str)]
(println line)))
(applet-function)
```
## License
Copyright © 2018 Sergey Sobko
Distributed under the MIT License. See LICENSE.
All the libraries and systems are licensed and remain the property of their respective owners.