# Correction-only continuity synthetic proof

This package tests whether a customer can receive and verify a correction warning after its data-read right expires, without receiving the replacement data.

It is a bounded synthetic proof, not a live provider integration, production entitlement system, or new Canon primitive claim.

## Run

```bash
npm run proof
```

The command does four things:

1. Generates fresh provider and customer Ed25519 keys.
2. Signs an 11-record synthetic evidence bundle.
3. Runs a separate offline continuity evaluation using only `bundle.json` and `trust.json`.
4. Runs two negative tests: a tampered correction and an attempted replacement-data disclosure.

The latest result is written to `artifacts/latest/test-results.json`.

## Acceptance coverage

| Requirement | Result | Evidence |
|---|---:|---|
| Post-expiry read request is denied | PASS | `read.after.expiry.denied` |
| Signed correction notice remains accepted | PASS | `notice.after.expiry.accepted` |
| Notice contains no replacement data | PASS | `notice.contains.no.replacement.data` |
| Local matching flags only recorded D1/D2 | PASS | `local.matching.flags.only.D1.D2` |
| Offline intact verification passes | PASS | `intact.offline.verification` |
| Offline tamper verification fails | PASS | `tampered.signature.rejected` |
| Retained provider/customer keys verify after access expiry | PASS | `retained.keys.verify.after.access.expiry` |

Current local run: **all tests pass**.

## Scenario

- The provider signs a split-rights policy.
- Data reads expire at `2026-10-22T17:00:00.000Z`.
- Correction notices remain available through `2026-10-22T23:59:59.000Z`.
- D1 and D2 are recorded against the same old source receipt.
- D3 is recorded without a source link.
- At 19:00, a data read is denied.
- At 19:05, the provider signs a correction notice.
- At 19:06 and 19:07, notice send and customer acceptance are signed.
- The local matcher flags D1 and D2 only.
- D3 remains unflagged because no link exists. That is not proof that D3 was unaffected.

## Disclosure boundary

The correction references the old source receipt and payload digest. Post-expiry records carry no replacement value, replacement version, replacement payload or raw content. The offline verifier scans the denied read result, correction notice, notice states and local match report for these forbidden disclosure fields.

The source generator contains only a synthetic placeholder value and does not persist it. Private keys are not persisted; the offline verifier uses public keys in `trust.json` only.

## Not proven

This package does not prove that:

- The provider already exposes a correction-notice entitlement.
- All unrecorded outputs were captured.
- A correction changed an outcome.
- A human read the warning.
- An opaque identifier is legally sufficient in a real license.
- The approach is novel or patentable.

Those are the next gates before any product or Canon claim.

## Package

- `src/generate.mjs`: creates the synthetic split-rights sequence.
- `src/verify.mjs`: standalone offline evaluator.
- `src/run-tests.mjs`: positive and negative test runner.
- `artifacts/latest/bundle.json`: signed evidence bundle.
- `artifacts/latest/trust.json`: retained public provider/customer keys.
- `artifacts/latest/test-results.json`: full results.
