Skip to content

AuditProof Specification

The AuditProof is a signed, hash-chained JSON document: verifiable evidence of a capsule's full lifecycle, from creation through execution to destruction. This page defines the canonical wire format. (The API resource and version field use the forever-stable cdp identifier.)

Version

Current wire version: cdp_version: "2.2". The offline verifiers accept 1.0, 2.1, and 2.2; 2.0 is retired and they refuse it as cdp_version_unsupported. The chain structure, hash algorithm (SHA-512), and signature scheme (Ed25519) are identical across the accepted versions, except that step 8 is amended when a proof carries receipt or parent roots (see Hash chain recomputation) and the signed message differs by version (see Signature basis); 2.x adds document-level fields additively.


Format Overview

An AuditProof contains five sections: metadata, the 8-step hash chain, the final hash, the cryptographic attestation, and context fields.

{
  "cdp_version": "2.2",
  "capsule_id": "cap_a8f3e71c...",
  "destroyed_at": "2026-03-01T14:04:58Z",
  "chain": [
    {
      "step": 1,
      "subsystem": "eee_namespace",
      "operation": "environment_isolation",
      "evidence_hash": "sha512:...",
      "chain_hash": "sha512:..."
    },
    {
      "step": 8,
      "subsystem": "capsule_destroy",
      "operation": "lifecycle_completion",
      "evidence_hash": "sha512:...",
      "chain_hash": "sha512:..."
    }
  ],
  "final_hash": "sha512:2c8a4f63d19e7b0a1f3c5d8e9b4a7c6f2d1e0a3b5c8d7e9f4a6b3c1d8e5f7a2b9c0d4e6f1a3b7c5d8e2f9a0b4c6d1e3f5a7b8c0d2e4f6a9b1c3d5e7f8a0b2c4d6",
  "attestation": {
    "algorithm": "Ed25519",
    "public_key": "base64:MCowBQYDK2Vw...",
    "signature": "base64:VGhpcyBpcyBh...",
    "key_id": "nrx-verify-2026-03-01T14-04-58Z-a8f3e71c"
  },
  "capsule_context": {
    "jurisdiction": "US",
    "data_classification": "PHI"
  },
  "regulatory_context": {
    "notice": "This mapping identifies regulatory provisions related to the destruction evidence. It is not a compliance certification. Compliance determinations should be made by qualified legal and compliance professionals.",
    "framework_version": "2026-08",
    "jurisdiction": "US",
    "mappings": ["..."]
  }
}

(The example elides six of the eight chain steps and shows placeholder hashes for readability; a real proof always carries all eight steps with full 128-hex-character SHA-512 values.)


Required Fields

These fields are present in every AuditProof Nanorix issues today (early 1.0 proofs lack destroyed_at). A proof without attestation is reported by the nanorix-verify CLI and the Python, TypeScript and Go libraries as chain-verified with the signature not checked (stage 4; exit code 3 from the CLI), by the web verifier as signature_mismatch at stage 7, and by POST /v1/verify as required_field_missing on 2.1 and 2.2 (a 1.0 proof without attestation fails there as signature_mismatch). For a proof whose destroyed_at is absent or empty, the verifiers use the timestamp recovered from attestation.key_id, which must have the form nrx-verify-YYYY-MM-DDTHH-MM-SS<tail>-<fragment> (colons in the time part are also accepted; for example nrx-verify-2026-05-06T12-00-00Z-a8f3e71c gives 2026-05-06T12:00:00Z).

Field Type Description
cdp_version string "1.0", "2.1", or "2.2" — current emission is "2.2"; "2.0" is retired and the offline verifiers refuse it
capsule_id string Capsule identifier
destroyed_at string ISO 8601 timestamp — when destruction completed. Also the timestamp input to every chain-step hash
chain array Ordered chain step objects (see below)
final_hash string SHA-512 value equal to the last chain step's chain_hash
attestation object Ed25519 signature and public key (see below)

The Eight Chain Steps

A complete AuditProof always carries exactly these eight steps, in this order:

Step subsystem operation (serialized) method (hash input, fixed constant)
1 eee_namespace environment_isolation procfs_verification
2 eee_tmpfs filesystem_isolation mountinfo_verification
3 eee_memory multipass_wipe dod_5220_multipass_wipe
4 dire_keys key_destruction ed25519_key_destruction
5 dire_identity credential_incineration credential_incineration
6 fgx_forensic merkle_zero_state merkle_tree_verification
7 rzl_audit chain_integrity_seal hash_chain_validation
8 capsule_destroy lifecycle_completion capsule_lifecycle_verification

Chain Step Object

Field Type Description
step integer Step number, 1 through 8
subsystem string Step identifier (table above)
operation string Operation performed by the step
evidence_hash string SHA-512 hash of the step's execution evidence
chain_hash string SHA-512 hash linking this step to the previous one

Hash Chain Recomputation

The chain is recomputable from the proof document alone — no Nanorix code or network access required:

chain_hash[n] = SHA-512(
    prev_hash ‖ 0x00 ‖ subsystem ‖ 0x00 ‖ "destroy" ‖ 0x00 ‖ method ‖ 0x00 ‖ timestamp
)
  • prev_hash is the previous step's chain_hash hex string (without the sha512: prefix); for step 1 it is the genesis value SHA-512(""): cf83e1357eefb8bdf1542850d66d8007d620e4050b5715dc83f4a921d36ce9ce47d0d13c5d85f2b0ff8318d2877eec2f63b931bd47417a81a538327af927da3e
  • ‖ 0x00 ‖ denotes concatenation with a single null byte between elements.
  • "destroy" is a literal action label, identical for every step.
  • method is the step's fixed canonical method constant from the table above. It is part of the specification, not the serialized proof; the serialized operation field is descriptive metadata and is not a hash input.
  • timestamp is the proof's destroyed_at value.
  • final_hash must equal step 8's chain_hash.
  • Step 8 is amended when the proof carries record_receipts_merkle_root or parent_proofs_merkle_root. Compute step 8 as above to get base (a hex string), then take SHA-512(base ‖ 0x00 ‖ rrmr), SHA-512(base ‖ 0x00 ‖ ppmr) or SHA-512(base ‖ 0x00 ‖ rrmr ‖ 0x00 ‖ ppmr), using whichever of the two roots is present, in that order, each with its sha512: prefix removed. A proof with neither root uses base unchanged.

An altered step, reordered chain, or edited timestamp changes every downstream chain_hash and breaks the equality — which is what makes the sequence tamper-evident.


Attestation

Field Type Description
algorithm string Always "Ed25519"
public_key string Base64-encoded Ed25519 public key, prefixed with base64:
signature string Base64-encoded Ed25519 signature, prefixed with base64:
key_id string Key identifier — nrx-kms-v{n} for an authority key (hosted and production proofs), or nrx-verify-{timestamp}-{capsule_id_prefix} for the development-only ephemeral signer

Signature Basis (version-dependent)

  • 1.0 — the signature is computed over the final chain hash's hex string as ASCII bytes (with the sha512: prefix stripped).
  • 2.x — the signature is over the SHA-512 of the canonical (RFC 8785 / JCS) serialization of the proof's fixed field view, which the verifier recomputes from the document; the full proof stores no hash of it.

Signing Modes

  • Authority-signed (hosted default; the production mode). The proof is signed by the deployment's signing authority — a long-lived Ed25519 key kept in a key service (Google Cloud KMS; the API's Vault signer, for a Vault or OpenBao Transit key, needs an install signing authority, so this release does not start with it). The proof carries authority_id and signing_key_version identifying the key lineage; the public key is embedded in the proof, stored when the capsule is destroyed and served at GET /v1/keys/:id, and an authority's registered key is served at GET /v1/authorities/:authority_id/keys/:key_version; the signed trust-chain manifest Nanorix publishes carries Nanorix's own authority, and a customer authority's key is anchored only by a key list that lists it, signed by an identity key the reader pins. On the Nanorix-hosted sandbox the authority is us-kms-nanorix-v1; a customer-run deployment signs with the key its operator configures. The capsule's own keys are not the signing key: they are minted per capsule and incinerated at teardown, which is what chain steps 4 and 5 record.
  • Ephemeral (development only). A fresh Ed25519 keypair is minted for that proof alone, signs exactly once, and is zeroized from memory. Such proofs stamp signing_key_version: "local-ephemeral", claim no authority, and cannot resolve in any trust-chain manifest.

Both modes verify identically offline for integrity: the public key needed to check the signature travels inside the proof. Only the authority-signed mode reaches an anchored verdict, because only a long-lived key can be listed in a manifest.


Optional Fields

These fields provide context but are not required for cryptographic verification.

capsule_context

Customer-declared metadata. Nanorix carries these declarations verbatim and does not verify them.

Field Type Description
jurisdiction string Customer-declared: "US", "EU", "UK", "CA", "AU", "IN", "OTHER"
data_classification string Customer-declared: "PHI", "PII", "financial", "credentials", "general"

metadata and metadata_hash

The metadata map a customer passes at capsule create is carried in the AuditProof as given. It sits outside the signed view, so the signature does not cover it. The capsule_started event in the full AuditProof's activity array (inside the signed view on 2.1 and 2.2, outside the 1.0 signature) carries metadata_hash, the SHA-512 of that map. No shipped verifier compares the two, so to detect a change to metadata, recompute the hash and compare it with the event's metadata_hash.

The hash is sha512: followed by the lowercase hex SHA-512 of the metadata written as one JSON object with its keys in sorted (UTF-8 byte) order, no whitespace between tokens, and non-ASCII characters left unescaped. Strings are escaped as in JSON: " and \ with a backslash, the control characters U+0000 to U+001F as \b \t \n \f \r or, for the rest, lowercase \u00xx, and nothing else (/, <, >, &, U+007F to U+009F and U+2028 are written as they are). The UTF-8 bytes of that text are hashed. In Python:

import hashlib, json

def metadata_hash(m: dict) -> str:
    text = json.dumps(m, sort_keys=True, separators=(",", ":"), ensure_ascii=False)
    return "sha512:" + hashlib.sha512(text.encode()).hexdigest()

This follows the server's metadata_hash_of (serde_json::to_string over a sorted string-to-string map), not an RFC 8785 library. Because metadata keys are limited to ASCII letters, digits, _, - and :, the bytes equal RFC 8785 output for every map the API accepts.

regulatory_context

A factual mapping of destruction steps to regulatory provisions, filtered by the customer's declared jurisdiction. See Regulatory Context.

Not a compliance certification

The regulatory_context field identifies regulatory provisions related to the destruction evidence. It is not a compliance certification. Compliance determinations should be made by qualified legal and compliance professionals. The field travels with the proof as reference context; the cryptographic chain and signature cover the proof's evidence fields.


Partial Proofs

If the instance handling a destroy does not track the capsule's runtime (after the instance that created it stops, when another instance holds it, or after an earlier destroy of it returned an error), no destruction step runs and the capsule's status still becomes destroyed. While the instance that created the capsule is still running, the capsule's runtime, with its keys and the data in its memory and tmpfs, stays live there unless an earlier destroy of the capsule had already torn it down; a repeat destroy is refused, and nothing in the service destroys that runtime before that instance stops. Unless that runtime was left by a destroy that stopped partway (including one that then returned an error), a graceful stop of that instance can tear it down, but writes nothing about it on the capsule and produces no AuditProof for it. A graceful stop does not complete the steps that a destroy which stopped partway did not run, and an abrupt stop runs nothing. The destroy run by the lifetime limit can be handled this way: each instance of the service that runs the lifetime limit runs it over every capsule, not only the ones it created, so that destroy can reach an instance that did not create the capsule. A partial document is stored and returned instead of an AuditProof:

{
  "cdp_version": "1.0",
  "capsule_id": "...",
  "created_at": "...",
  "destroyed_at": "...",
  "completeness": "partial",
  "reason": "capsule_state_lost_on_restart",
  "note": "...",
  "chain": [],
  "final_hash": null,
  "attestation": null
}

The partial document carries an empty chain — no destruction steps ran, so there is nothing to chain — a null final_hash and a null attestation: it is not signed. It declares version 1.0 and has no signing_key_version. Its note states only what the service recorded. The verification_cdp summary that accompanies it declares version 2.2, is unsigned (attestation algorithm none), and carries environment, data_ingested and data_extracted as null when the service holds no observation for them. A complete proof always carries exactly 8 steps. POST /v1/verify does not accept the partial as a proof: it reports step_count_invalid with found 0. It does not accept the summary either: as a 2.2 projection it takes the stripped-projection path and is reported invalid with step_hash_mismatch and a stripped_projection: scope. A summary issued by an earlier build declared 2.0; the hosted route evaluates it with the 2.0 check and reports step_count_invalid with found 0, with no scope (an invalid 2.0 verdict carries none).


Verification

AuditProofs can be verified three ways:

  1. Offline — recompute the chain from genesis with the formula above, check final_hash equals step 8's chain_hash, recompute the version-appropriate signature basis, and verify the Ed25519 signature with the embedded public_key. Zero network calls.
  2. API — POST /v1/verify with the proof JSON body. Stateless, no authentication.
  3. Web — drag-and-drop at nanorix.io/verify. Runs entirely client-side.

Step-by-step instructions: Verification.


Versioning

  • 1.0 — original single-document format. Chain + final hash + attestation; signature over the final chain hash.
  • 2.0 — retired for signed proofs. A two-layer document: the same chain wrapped in a document whose signature covered a hash that no published rule lets a verifier recompute from the document (the summary projection carries it only as a declared document_hash string). The offline verifiers refuse it at the version gate as cdp_version_unsupported. The service no longer issues documents labelled 2.0: the unsigned verification_cdp summary returned with a partial destroy (see Partial Proofs) is labelled 2.2. Nanorix serves a historical 2.0 document as stored by default; the stored record is the document as issued, and ?format=presentation is refused for it. The POST /v1/verify route keeps a check for 2.0-labelled documents already delivered: it verifies the Ed25519 signature over the declared document_hash string under the key embedded in the document, reports it under the scope declared_hash_only:, and never anchors it; that string is all the signature covers, because no published rule lets a verifier recompute the hash from the document.
  • 2.1 — Restores destroyed_at to the serialized document so independent verifiers can recompute chain-step timestamps without any out-of-band data.
  • 2.2 — current. Verifies and is signed exactly as 2.1 (the canonical-view hash is computed the same way and is the signed message); it changes what a document may carry, not how it is hashed or signed. It adds two things, both inside the signed canonical view, so a value rewritten after signing fails the signature check:
    • a policy_denial_summary activity event, written on a destroy that completes the chain. It lists, per check, how many refusals that check issued (by_reason: a reason and a count per row) and the time of the summary (at). It counts refusals at the listed checks only, not attempts and not traffic the runtime did not see. A row with count: 0 means the check ran and refused nothing; an empty by_reason means no listed check ran. The event is absent from a document when runtime state was unavailable (for example after a server restart, when the destroy reached an instance that did not create the capsule, or after an earlier destroy of the capsule returned an error), and absence means exactly that.
    • an optional top-level customer_declared_activity_root, present only when the capsule opted in at creation. It is a sha512: commitment (SHA-512 Merkle root over the lines of the activity record the customer's own code produced, bound to the line count). Nanorix does not parse that record; the customer holds it and can recompute the root from it. On 1.0, which does not sign the canonical view, a populated root is rejected as an unsigned field.

Evolution is strictly additive: fields are never removed or renamed, the 8-step chain structure and algorithms (SHA-512, Ed25519) are frozen, and previously issued proofs of a supported version remain verifiable forever; 2.0, above, is the one retired version.