Files
trezor-firmware/rust/trezor-thp
Martin Milata 191b8643eb feat(rust/trezor-thp): add example client
[no changelog]
2026-02-11 15:03:48 +01:00
..

trezor-thp

Rust library for Trezor Host Protocol. THP facilitates communication between an application on a host computer and a Trezor cryptocurrency wallet.

To learn more about THP, please see the full specification.

Design

The goal of the library is to be used by both bare-metal firmware and desktop applications.

  • Implements both the Host and the Device (Trezor) side.
  • Usable on no_std and without core::alloc.
  • I/O-free to make integration into any kind of event loop possible.
  • Usable with any protobuf and cryptography libraries.
  • Minimal dependencies.

Due to these requirements, the crate is very low-level - it provides a library of components that you need to assemble to get a high-level abstraction of THP sessions.

Crates that provide a higher-level interface:

Examples

The examples assume Trezor emulator available through UDP.

cargo run --example transport-level-ping
cargo run --example host-cli

Features

None yet.

Other implementations

Credits