Skip to main content

Crate thaiidcard

Crate thaiidcard 

Source
Expand description

libthai-idcard — A Rust library for reading Thai National ID smart cards via PC/SC card readers. Supports personal information, NHSO insurance data, and the laser-engraved card serial number.

§Basic usage

use thaiidcard::{SmartCard, Options};

let card = SmartCard::new();
let data = card.read(None, &Options::default()).unwrap();
println!("Name: {}", data.personal.unwrap().name.full_name);

Re-exports§

pub use options::Options;

Modules§

apdu
APDU command bytes for Thai National ID smart card applets. Reference: https://github.com/chakphanu/ThaiNationalIDCard/blob/master/APDU.md
ffi
C-compatible FFI for libthai-idcard.
model
Data types for Thai National ID smart card data.
options
Options for configuring card reads.
reader
Low-level PC/SC card operations and APDU transport.

Structs§

SmartCard
Main handle for reading Thai National ID smart cards.

Enums§

Event
Events emitted by SmartCard::start_daemon.