Skip to main content

Independent verifier for AqtaCore attestation receipts (AI governance). Verifies the Ed25519 signature on an attestation receipt without trusting Aqta's servers. Reference implementation of ATTESTATION-v1.

Project description

aqta-verify-receipt

Independent verifier for AqtaCore attestation receipts. Checks the Ed25519 signature on an enforcement-attestation receipt using only the published public key — no dependency on Aqta's servers.

Why this exists

AqtaCore returns a signed receipt with every AI enforcement decision. Regulators, auditors, and internal compliance teams need to verify those receipts independently — without trusting the issuer. This package is the reference implementation of that verifier, maintained by Aqta under the open ATTESTATION-v1 format specification.

Install

pip install aqta-verify-receipt

Usage

from aqta_verify_receipt import verify_receipt, fetch_published_public_key

# One-time: fetch and pin the issuer's public key.
trusted = fetch_published_public_key()

# Per receipt:
result = verify_receipt(receipt, trusted_public_key=trusted)

if not result.valid:
    raise ValueError(f"Receipt invalid: {result.reason}")

print("Receipt verified without contacting Aqta.")

API

verify_receipt(receipt, *, trusted_public_key=None, strict_fields=True) → VerifyResult

Verifies an attestation receipt against the declared (or pinned) public key.

  • trusted_public_key — base64url public key. If set, receipt's public_key field must match byte-for-byte. Strongly recommended for production.
  • strict_fields — if True (default), any unknown top-level field causes rejection, per ATTESTATION-v1 §4.

Returns a VerifyResult with fields valid: bool and reason: Optional[str]. Never raises.

fetch_published_public_key(url=..., *, timeout=10.0) → str

Fetches the AqtaCore public key from https://app.aqta.ai/security/pubkey.txt. Pass a custom URL for self-hosted issuers.

Dependencies

  • cryptography for Ed25519 verification (pinned ≥ 42.0.0).

No other dependencies. Pure-Python spec checks, plus cryptography's constant-time Ed25519 primitive.

Receipt format

See ATTESTATION-v1.

Licence

Apache-2.0. See LICENSE.

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

aqta_verify_receipt-1.0.0.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

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

aqta_verify_receipt-1.0.0-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file aqta_verify_receipt-1.0.0.tar.gz.

File metadata

  • Download URL: aqta_verify_receipt-1.0.0.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.8

File hashes

Hashes for aqta_verify_receipt-1.0.0.tar.gz
Algorithm Hash digest
SHA256 73162faf32d4f8635893edee059e42d9aee94c58494cb4af9ea05885beb1c40d
MD5 f62f62c88c3f98d3a1244b5d977e0af3
BLAKE2b-256 8f1fbc1dd595532ca5c197bf6b969df29bd91378993181be924fb57de97c14d3

See more details on using hashes here.

File details

Details for the file aqta_verify_receipt-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for aqta_verify_receipt-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 500a86734bdb9abfea43e0df47fe09aece695d96414a24f39f6302224f7c0878
MD5 76ee946ff1447afdd7f7fcace567b6f6
BLAKE2b-256 3baba7e894db5f4bdac1f277083e692995362aba539e10e4f6849281f22a6cb5

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