Skip to main content

Stateless verification for Bitcoin handles using the Spaces protocol

Project description

libveritas

Python bindings for libveritas — stateless verification for Bitcoin handles using the Spaces protocol.

Installation

pip install libveritas

Usage

from libveritas import Anchors, Veritas, QueryContext, Message

# Load trust anchors
anchors = Anchors.from_json(anchors_json_string)
veritas = Veritas(anchors)

print(f"Anchors: {veritas.oldest_anchor()} .. {veritas.newest_anchor()}")

# Build query context (empty = verify all handles)
ctx = QueryContext()

# Verify a message
msg = Message(message_bytes)
result = veritas.verify_message(ctx, msg)

# Inspect verified zones
for zone in result.zones():
    print(f"{zone.handle()} -> {zone.sovereignty()}")

# Get certificates
for cert in result.certificates():
    print(f"{cert.subject} [{cert.cert_type}]")

Building from source

Requires Rust and maturin:

pip install maturin
cd python
maturin develop

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

libveritas-0.0.0.dev20260322225438-py3-none-win_amd64.whl (2.0 MB view details)

Uploaded Python 3Windows x86-64

libveritas-0.0.0.dev20260322225438-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.2 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

libveritas-0.0.0.dev20260322225438-py3-none-macosx_11_0_arm64.whl (2.1 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

File details

Details for the file libveritas-0.0.0.dev20260322225438-py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for libveritas-0.0.0.dev20260322225438-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 b4339fc6210961578c5fef661d9277099e4d102ce000569266c43a43946b7ed9
MD5 e4f588cc32fcb452d8a6719a600758d8
BLAKE2b-256 dec98ebf825ce98ebad1b421e435fe62c15f9a78d24198314a32d69845509d28

See more details on using hashes here.

File details

Details for the file libveritas-0.0.0.dev20260322225438-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for libveritas-0.0.0.dev20260322225438-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 084595ac25070364ed4c1a7f5feb00184731a3190537afc832a175263e915f64
MD5 be51d0a6af9e7bc489bc62e3234cfb0a
BLAKE2b-256 cbf23f558da08793044ca671ed58f4f13435649a9af0b74fe04ad04c1d840cc4

See more details on using hashes here.

File details

Details for the file libveritas-0.0.0.dev20260322225438-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for libveritas-0.0.0.dev20260322225438-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 4fed9bfc2fc42f4d40b722e54979a1dece471d1e15c6850dbd270ece13d98170
MD5 5a0da539816478320eb40b8956acc959
BLAKE2b-256 19d079fe4ced26ff9509a857405357fd6c48c6f5ef49cfe4afc1733736523740

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