Skip to main content

KeyCard Python SDK - APDU communication and cryptographic utilities.

Project description

KeyCard Python SDK

License Python codecov PyPI version Build status Documentation stars lastcommit numcontributors

A minimal, clean, fully native Python SDK for communicating with Keycard smart cards.

This SDK is under active development.
APDU commands are being implemented one by one.

Supported Commands

  • SELECT
  • INIT
  • IDENT
  • OPEN SECURE CHANNEL
  • MUTUALLY AUTHENTICATE
  • PAIR
  • UNPAIR
  • GET STATUS
  • VERIFY PIN
  • CHANGE PIN
  • UNBLOCK PIN
  • LOAD KEY
  • DERIVE KEY
  • GENERATE MNEMONIC
  • REMOVE KEY
  • GENERATE KEY
  • SIGN
  • SET PINLESS PATH
  • EXPORT KEY
  • STORE DATA
  • GET DATA
  • FACTORY RESET

Goals

  • Fully native Python implementation
  • Clean API surface
  • Easy to integrate
  • Clear separation between transport, protocol, parsing, and crypto
  • Fully tested, deterministic behavior
  • Focused on correctness, clarity, and maintainability

Installation

git clone https://github.com/mmlado/keycard-py.git
cd keycard-py
python -m venv venv
source venv/bin/activate
pip install -e .
pytest

License

MIT

Contributions

Contributions are welcome as this SDK grows.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

keycard-0.3.0.tar.gz (46.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

keycard-0.3.0-py2.py3-none-any.whl (38.8 kB view details)

Uploaded Python 2Python 3

File details

Details for the file keycard-0.3.0.tar.gz.

File metadata

  • Download URL: keycard-0.3.0.tar.gz
  • Upload date:
  • Size: 46.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.32.5

File hashes

Hashes for keycard-0.3.0.tar.gz
Algorithm Hash digest
SHA256 03130e1690ad4c517a4c02acdd2a625142bc448c4d68421fe1004848c090d09b
MD5 c61b5f62c5f80c66604c23dabe8ad7d1
BLAKE2b-256 81e50a173ac6a95c6647466a724a31178b2177dd7ee888eca308e9c08443dbdf

See more details on using hashes here.

File details

Details for the file keycard-0.3.0-py2.py3-none-any.whl.

File metadata

  • Download URL: keycard-0.3.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 38.8 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.32.5

File hashes

Hashes for keycard-0.3.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 0646a5cd97aaae078e5b34ae28f8a4a99576bab00e674b2722bbe9d70977be9c
MD5 3c242c6d42a2deee78e2df0d90303a34
BLAKE2b-256 f0340d7300a3f4edef86b3062d42f235ee44ac805a57ef21526c8948ac8f00e3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page