keycard-sdk

nim SDK to interact with the Status Keycard

Pure Nim score 15/100 · tests present · no docs generated

Summary

Latest Version 0.1.0
License MIT
CI Status Failing
Downloads 0
Last Indexed 2026-07-21 05:27

Authors

  • mmlado

Installation

nimble install keycard-sdk
choosenim install keycard-sdk
git clone https://github.com/mmlado/keycard-nim

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
keycard-sdk - - - - - - -

Dependencies

Package Version Optional
nim >= 1.6.14 No
pcsc - No
nimcrypto - No
https://github.com/status-im/nim-secp256k1 - No

Source

Repository https://github.com/mmlado/keycard-nim
Homepage https://github.com/mmlado/keycard-nim
Registry Source nimble_official

README

keycard-nim

A Nim SDK to interact with the Status Keycard - a hardware wallet implementation on JavaCard.

Documentation

Installation

git clone https://github.com/mmlado/keycard-nim.git
cd keycard-nim
nimble install

Dependencies

  • pcsc-nim - PC/SC library for smart card access
  • Nim >= 1.6.14

Quick Start

import keycard/keycard
import keycard/commands/select
import keycard/transport

# Create keycard instance
let t = newTransport()
var card = newKeycard(t)

# Connect to first reader
let readers = card.listReaders()
card.connect(readers[0])
defer: card.close()

# Select the Keycard applet
let result = card.select()
if result.success:
  echo "Card version: ", card.version()
  echo "Initialized: ", card.isInitialized()
  echo "Secure channel: ", card.hasSecureChannel()

Testing

Run tests with mock PC/SC (no hardware required):

nimble test

Run example with real card:

nimble example

Clean build artifacts:

nimble clean

Contributing

Contributions welcome! Please: 1. Run tests before submitting (nimble test) 2. Follow existing code style 3. Add tests for new features 4. Update this README with implementation status

License

MIT

References