Skip to main content

chp-safety-case

The portable .chpsafety Safety Case bundle format and its offline verifier — part of the Capability Host Protocol runtime-assurance work.

A Safety Case is the artifact you hand to a security reviewer, an auditor, or a customer to answer "what was this AI agent authorized and technically able to do, and did the controls hold?" — a file, not a screenshot. This package verifies one anywhere, with no network and no trust in the producer: it recomputes every artifact digest (tamper-evidence) and checks the Ed25519 signature over the manifest. Deliberately minimal — stdlib + cryptography only, no chp-core, no mesh.

Install

pipx install chp-safety-case      # or: pip install chp-safety-case

Verify a bundle

chp-safety-case verify case.chpsafety
{
  "manifest_valid": true,     // every file matches its recorded sha256; no unsigned files present
  "signature_valid": true,    // the Ed25519 signature over the manifest checks out
  "signer_trusted": false,    // true only when you pass the signer's key via --trusted-key
  "integrity_valid": true,    // manifest_valid AND signature_valid
  "errors": []
}

Exit codes: 0 ok, 2 integrity failed, 3 --require-trusted-signer set and the signer wasn't trusted. Pin a signer you trust:

chp-safety-case verify case.chpsafety --trusted-key my-node=signer.pub.hex --require-trusted-signer

As a library

from chp_safety_case import verify_safety_case_bundle

r = verify_safety_case_bundle("case.chpsafety")
assert r.integrity_valid        # tamper-evident: any edit to any artifact breaks this

What's in a bundle

A .chpsafety file is a zip of case.json (the Safety Case), its evidence artifacts, a manifest.json (sha256 of every file), and a signature.json (Ed25519 over the manifest). The verifier trusts none of the producer's own booleans — it recomputes the digests and checks the signature itself.

License

Apache-2.0.

Metadata

Release files for chp-safety-case 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for chp-safety-case 0.1.0
File Size Uploaded
chp_safety_case-0.1.0.tar.gz 9.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for chp-safety-case 0.1.0
File Interpreter ABI Platform
chp_safety_case-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.1 kB

Release files / chp_safety_case-0.1.0.tar.gz

Download URL chp_safety_case-0.1.0.tar.gz
Size 9.3 kB
Tags Source
SHA-256 checksum
How to use checksums
c8fb71c4fdafe2a553eae5c22a933546c696a8a13f489060979cde3e49ffa624
BLAKE2b-256 checksum
How to use checksums
fa6ddd75eb156d99c829222d4c5568dbcd0ad25c334e9ef13a26f1684448d3b9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 8, 2026.

Transparency log

Release files / chp_safety_case-0.1.0-py3-none-any.whl

Download URL chp_safety_case-0.1.0-py3-none-any.whl
Size 10.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9efadf74c3e58c15f11c02e293122bfca59a3331c180eaf4f1a08340588d64da
BLAKE2b-256 checksum
How to use checksums
1500de3d9b2fdc3bdcc06bbca05d351eb195d7d2ba6eaadabfbbd0ec63debd06
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 8, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page