Skip to content

Rule Q6: PHI on chain means COMMITMENTS, with the alternative rejected on merits - #476

Closed
brettheap wants to merge 1 commit into
mainfrom
change/rule-q6-commitments
Closed

brettheap wants to merge 1 commit into
mainfrom
change/rule-q6-commitments

Conversation

@brettheap

Copy link
Copy Markdown
Contributor

Brett ruled this on 2026-08-28 after working the alternative through, rather than accepting the topic's reading on trust. Q6 was the one question where this topic had interpreted a ruling instead of applying it.

The alternative was put, and rejected on its merits

Brett proposed encrypting the PHI and placing it on chain, tied to the de-PHI'd record through the patient wallet — on the grounds that an immutable record cannot be forged or altered. That goal is correct, and it names a real gap in the FHIR/TEFCA rails US interoperability actually runs on.

It fails on one observation:

The integrity property does not come from the location of the bytes.

A signed record whose salted commitment is anchored is exactly as forgery-resistant as one published on chain — alter a byte and the commitment breaks. Publishing the ciphertext adds permanence without adding integrity, and permanence costs three things that bite harder for PHI than almost any other data:

Cost Why it bites
Harvest now, decrypt later 50–100 year sensitivity window, longer than any responsible crypto assumption; a future key compromise exposes everything retroactively with no withdrawal
No erasure crypto-shredding is contested, and EDPB 02/2025 reasons about ciphertext as it does about hashes
Right to amend HIPAA §164.526 — an append-only chain leaves the erroneous record permanently readable

The ruled design keeps every property the alternative reached for

Signed by the issuing clinician under trust-anchor · encrypted off chain under patient-held keys · one salted keyed commitment per record, anchored — and that commitment is the tie between de-PHI'd record and PHI · salt in the wallet · amendment by supersession · erasure by salt destruction, which breaks the link rather than asserting it is broken.

Unforgeable · alteration-evident · patient-controlled · amendable · erasable.

What the chain still does

Recorded because the narrowing invites the question. One job: being a witness nobody controls — including us. The transparency log is operator-run, so "trust us, we didn't rewrite it" is exactly the assurance a hospital, insurer or court shouldn't have to accept.

The honest alternative is named rather than hidden: independent operators cross-signing checkpoints (the Certificate Transparency model) would give a similar property without a chain. The chain wins on having no consortium to keep honest, and a marginal cost of ~zero via OpenTimestamps aggregation.

Status

Q3 and Q6 both answered — tranche three is unblocked on rulings. Q7 still gates tranche two.

doc-health --single-repo is byte-identical to the origin/main baseline (5 critical, 11 error, 11 info, 41 warning) — all pre-existing, none touching these files.

🤖 Generated with Claude Code

…d on merits

Brett Heap ruled 2026-08-28 after working the alternative through rather than
accepting the topic's reading on trust. Q6 was the one question where this
topic had INTERPRETED a ruling instead of applying it; it is now the ruling's
operative form and no later change may re-litigate it without a fresh ruling.

THE ALTERNATIVE WAS PUT AND REJECTED ON ITS MERITS. Brett proposed encrypting
the PHI and placing it on chain, tied to the de-PHI'd record through the
patient wallet, on the grounds that an immutable record cannot be forged or
altered. That goal is correct and names a real gap in the FHIR/TEFCA rails US
interoperability actually runs on.

It fails on one observation: THE INTEGRITY PROPERTY DOES NOT COME FROM THE
LOCATION OF THE BYTES. A signed record whose salted commitment is anchored is
exactly as forgery-resistant as one published on chain -- alter a byte and the
commitment breaks. Publishing the ciphertext adds permanence without adding
integrity, and permanence costs three things that bite harder for PHI than for
almost any other data: harvest-now-decrypt-later across a 50-100 year
sensitivity window with no withdrawal possible; no erasure, since
crypto-shredding is contested and EDPB 02/2025 reasons about ciphertext as it
does about hashes; and a collision with HIPAA 164.526's right to amend, where
an append-only chain leaves the ERRONEOUS record permanently readable.

The ruled design keeps every property the alternative reached for -- signed by
the issuing clinician under trust-anchor, encrypted off chain under
patient-held keys, one salted keyed commitment per record anchored and serving
AS the tie between de-PHI'd record and PHI, salt held in the wallet, amendment
by supersession, erasure by salt destruction which BREAKS the link rather than
asserting it is broken. Unforgeable, alteration-evident, patient-controlled,
amendable, erasable.

Also records what the chain still does, because the narrowing invites the
question: one job, being a witness nobody controls INCLUDING US. The
transparency log is operator-run, so "trust us, we did not rewrite it" is
exactly the assurance a hospital, insurer or court should not have to accept.
The honest alternative -- independent operators cross-signing checkpoints, the
Certificate Transparency model -- is named rather than hidden; the chain wins
on having no consortium to keep honest and a marginal cost of about zero.

Q3 and Q6 are now both answered, so tranche three is unblocked on rulings. Q7
still gates tranche two.

doc-health --single-repo is byte-identical to the origin/main baseline: 5
critical, 11 error, 11 info, 41 warning, all pre-existing and none touching
these files.

Co-Authored-By: Claude Opus 5 <[email protected]>
Copilot AI lite review requested due to automatic review settings August 28, 2026 10:15

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @brettheap! 👋

Your private repo does not have access to Sourcery.

Please upgrade to continue using Sourcery ✨

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the signed-execution-chain ideation topic to record Brett Heap’s 2026-08-28 ruling for Q6 (PHI “on chain” interpreted as commitments), including documenting the considered-but-rejected alternative and its rationale, and propagates that status into the staging index.

Changes:

  • Marks Q6 as answered (2026-08-28) and adds a detailed write-up of the alternative design and why it was rejected.
  • Clarifies the remaining role of the chain (external witness against operator rewrite) and the tranche gating status in the topic narrative.
  • Updates the staging INDEX entry to reflect Q6 as ruled/answered and summarizes the merits-based rejection.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
ideation/staging/signed-execution-chain/signed-execution-chain.md Records Q6 as answered and adds the merits-based rationale for commitments vs encrypted PHI on-chain.
ideation/staging/INDEX.md Updates the signed-execution-chain row to reflect the Q6 ruling and updated status summary.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

the right to request amendment, and corrections are routine — wrong
patient, wrong lab, transcription error. An append-only chain can record a
superseding entry, but the ERRONEOUS record stays permanently readable. A
mis-attributed diagnosis becomes an unrevokable publication.
@brettheap

Copy link
Copy Markdown
Contributor Author

Superseded by #499 (squash 9c501df6), which ruled all seven of the staged topic's open questions in Brett Heap's 2026-08-29 clarify sitting — Q6 among them, CONFIRMED as recommended and recorded as the 2026-08-27 ruling's OPERATIVE FORM: "patients put PHI portions on chain" means SALTED KEYED COMMITMENTS, the portion disclosed off-chain under an anchored consent checkpoint, salt destruction as the erasure mechanism, and literal raw, encrypted and plain-hashed PHI on chain all still REFUSED. The disposition adds that no later change re-litigates it. This PR's single question is therefore answered on main, and its branch had been conflicting and untouched since 2026-08-28.

@brettheap brettheap closed this Aug 29, 2026
@brettheap
brettheap deleted the change/rule-q6-commitments branch September 2, 2026 18:53
brettheap added a commit that referenced this pull request Sep 22, 2026
…literal, and the specs/025 row (#1136)

Lane: openxfactory-4 (openXfactory-4-openDox_extraction)

**`lockstep.status: diverged → converged`, with its test literal, in one commit — the fourth re-point ceremony discharged the obligation.** Plus the `specs/025` ledger row, which is two transitions stale and is caught up here.

## The act in the other repository

This file's `lockstep` block has said, since it was written, that re-converging is *"an act in ANOTHER repository and this pull request does not take it."* That act has now been taken. **`opensoft/xFactory#475` → merge commit `c88d1fdd`, 2026-09-21T21:55:36Z**, the FOURTH `MIGRATION_PIN` re-point ceremony, advanced `1f131a23 → b21f0100` at its three surfaces in one commit (`96d0b91b`, 3 files / 3 insertions / 3 deletions) on Brett Heap's explicit ceremony word of 2026-09-21 — *"(a) for all four, (i) for the tag, keep going"*, item 2, recorded at [#656 comment 5767804734](#656 (comment)).

**The direction matters and is the reason this convergence is a discharge rather than another advance.** The ceremony's target was not negotiated: `b21f0100` is the commit `core_commit` here has named since PR #1122 (merge `38f826c2`, 2026-09-18). The aggregation moved **to** this file. That is exactly what `obligation:` asks for — *"A future re-point ceremony should converge all three surfaces onto one commit"*.

**And the ORDER is the part that is genuinely first** — stated precisely, because a looser version of this claim was wrong and Copilot caught it (below). Every earlier convergence was a **paired window**: at the third, `opensoft/xFactory` PR #423 merged 2026-09-10T19:15:29Z and this file's `core_commit` followed the same evening at PR #922 (merge `6f95ff57`, 21:55:20Z) — two halves of one ruled pairing (OQ-1 option C, *"paired with openxFactory's five-site advance"*). This time the two moves are **three days apart** and were never a pairing: `core_commit` advanced on 2026-09-18 by an hourly lane that proposes such advances on its own, and the ceremony caught the aggregation up to where this file had been sitting since. That is the first time the aggregation has converged onto a commit this file was **already** pinned to.

## Measured, not assumed

Taken the way every measurement in this field has been taken, and deliberately taken **two commits past the ceremony merge**, at xFactory `main` `cfe27de3`, so the reading survives a routine submodule-pointer sync (PR #476) instead of resting on the merge commit alone:

| site | value |
| --- | --- |
| xFactory `.github/workflows/merge-master-approval.yml:152` | `b21f0100…` |
| xFactory `.github/workflows/council-convening-lane.yml:308` | `b21f0100…` |
| xFactory `tests/test_merge_master_workflows.py:66` `MIGRATION_PIN` | `b21f0100…` |
| openxFactory `contracts/review-lane-pin.yaml:60` `core_commit` (main `6b298a1e`) | `b21f0100…` |

Four sites, one commit. That a **routine** sync ran in between and left all three xFactory surfaces alone is itself the aggregation's working rule 2 holding: `MIGRATION_PIN` moves at a ceremony and at nothing else.

**And the ceremony's after-check passed**, which is what makes `converged` a claim about behaviour rather than only about text. Gates G1–G4 are recorded in `96d0b91b`'s own commit message; **G5** — the live lane re-proved at the NEW pin — is recorded at [xFactory#475 comment 5769610282](opensoft/xFactory#475 (comment)): three post-landing runs (`35660330263`, `35660933433`, `35661430301`) each concluded `success`, each with `b21f0100` read out of its own checkout log and **zero** occurrences of the superseded pin, each judging the **same candidate object** as the pre-act baseline run `35658107765`, and each emitting a decision whose canonical sha256 is identical to that baseline's. The pin moved and the verdict did not.

## What moves here, and why it is one commit

| file | change |
| --- | --- |
| `contracts/review-lane-pin.yaml` | `lockstep.status` `diverged` → `converged`; an appended `reason:` paragraph recording the convergence |
| `tests/review_lane_pin/test_review_lane_caller.py` | `test_the_pin_records_its_lockstep_state_with_the_aggregation_pin`'s asserted literal `diverged` → `converged`; one appended docstring paragraph |
| `specs/025-openxfactory-review-lane-caller/tasks.md` | task 6.5 gains a dated append; **stays unticked** |

The first two move **together, in one commit**, because that is this field's own written convention and what every prior transition did — PR #483 / `d118bc79` (converge), PR #569 / `47f90080` (diverge), the 2026-09-10 flip `d8bdc58a`, the 2026-09-18 re-divergence `7fd8fa5f`. The assertion is a literal `assertEqual`, not a membership test, so flipping the data alone turns a green `pytest-suite` red.

**No pin value moves in this diff.** `core_commit`, `floor_snapshot.sha256` and `floor_snapshot.entry_count` are untouched; the vendored snapshot and both workflows are not in the diff at all. Nothing here touches `MIGRATION_PIN` itself — that is the ceremony's act and it has already landed.

## Four decisions worth naming rather than leaving to be found

**1. `reason:` is APPENDED, not rewritten.** The field's own text states the convention (*"an appended fix, not an edit of it, per this field's own append-only convention"*), and all four prior transitions appended. The appended paragraph ends the field, so `reason:` now reads as the converged narrative — without deleting the dated measurements the ceremony trail is built on.

**2. Every SHA in the contract is written SHORT.** `test_the_pin_carries_exactly_one_commit_shaped_value` permits exactly ONE 40-hex token in the whole file, and that one is `core_commit`. Verified after the edit: the only 40-hex token in the file is `b21f010013fa51960c77377a8582943435b6db32`.

**3. `converged_with:` keeps TWO entries and gains no third.** The test at line 636 asserts `len == 2` with the message *"both xFactory merge-master surfaces must be named"*. Those two are the **judging** surfaces — where a core is actually checked out and run — while `MIGRATION_PIN` is the aggregation's own test holding them identical to each other. It is named in the measurement without being promoted to a member, as through both prior cycles. Adding a third would change a shape no transition has touched since `d118bc79`.

**4. The header comment above `lockstep:` is left exactly as written.** It still narrates the 2026-09-01/09-04 forced divergence and still ends *"written down as diverged"*. It is a **dated measurement**; the 2026-09-10 convergence left it standing for the same reason. Rewriting a dated measurement is how a record stops being one, and `lockstep.status` — not that comment — is where the live state is declared. The appended paragraph names this tension explicitly so the next reader finds it already seen.

## The `specs/025` row, and why it stays unticked

Task 6.5 was last written on **2026-09-02** (`47f90080`). Measured rather than remembered — `git log -- specs/025-openxfactory-review-lane-caller/tasks.md` records no commit after it — so **neither** lockstep transition since wrote there: `d8bdc58a` and `7fd8fa5f` each moved the contract and its test literal and stopped. The row was two transitions stale, and the append says so rather than quietly filling the gap. It now records all three: the 2026-09-10 convergence, the 2026-09-18 **routine** re-divergence, and this ceremony.

**It stays `- [ ]`, and the reason is new.** Its own criterion — *"BOTH halves true at once"* — is satisfied for the first time. What withholds the tick is not a missing act but the **durability** a tick asserts: since `mirror-floor-regeneration-automation` was realized, the hourly `review-lane-repin` lane can advance `core_commit` between ceremonies with auto-merge armed, and the 2026-09-18 re-divergence is precisely that happening. Convergence is therefore falsifiable by this repository's own automation within the hour, while a ticked box claims a standing state. The live state is `lockstep.status`; this row carries history — the same idiom as 6.3's *"STAYS UNTICKED, and the reason has changed"*. Ticking it, or narrowing the `obligation:` clause that still assumes only ceremonies advance this pin, is the ratifier's act.

## Proven

- `python3 -m pytest tests/review_lane_pin -q` → **198 passed, 2 skipped, 54 subtests** — the same counts `d8bdc58a` and `7fd8fa5f` each recorded, with the assertion now reading `converged` against the file's `converged`.
- `python3 openXwallet/scripts/wallet-yaml-syntax-gate.py .` (the pinned gate the required `wallet-validation` check runs) → **exit 0**.
- `scripts/validate-pin-registrations.py`, `scripts/validate-manifest-digests.py`, `scripts/validate-workflow-contracts.py` → **exit 0** each. No validator names this contract; `tests/review_lane_pin/` is what stops it drifting, by its own CODEOWNERS note.
- `yaml.safe_load` of the edited contract: `status: converged`, `len(converged_with) == 2`, exactly one 40-hex token in the file.

## Review round 1 — three findings, all fixed rather than argued

Copilot reviewed at `fe7ca396` and raised three Low findings. **All three were factual errors in text this branch added**, so all three were fixed (`587fdc40`), replied to with the measurement, and resolved — none was argued down.

1. **`contracts/review-lane-pin.yaml` — the "first convergence" claim was false.** The appended paragraph said this was the first convergence closing a re-divergence this repository caused; the 2026-09-10 flip already did that, closing the 2026-09-01 re-divergence the (b′) activation caused here by hand. The paragraph now says it closes the **2026-09-18** re-divergence, explicitly declines the broader claim, and states what is actually first — the unpaired order described above.
2. **`specs/025` — the count was wrong.** *"discharged and re-incurred TWICE MORE"* distributed "twice more" over both verbs. Measured from the paragraph above: **discharged twice more** (2026-09-10, 2026-09-21), **re-incurred once more** (2026-09-18). Fixed, and the ambiguous *"this row missed both"* became *"this row recorded none of the three movements"*.
3. **The test docstring carried an unqualified present tense.** *"THE CURRENT CONTRACT IS `diverged`; … is not taken here"* sat in the same docstring as the new paragraph and directly above the assertion, contradicting both. It moves to the past tense of its own dated measurement. **This is deliberately not done to the contract's header comment** one file over: that header is a dated narrative standing *above* the field, and `lockstep.status` is where the live state is declared, so the appended paragraph records that tension instead. A sentence inside the same docstring as its own contradiction is a different thing from a dated narrative elsewhere in the file.

A fourth correction was **self-caught** on a read-back and is not Copilot's (`ac764dbd`): the parenthetical pointed *"two paragraphs down"* at a paragraph one down.

## Review round 2 — one High finding, answered by measurement and **recorded in the file**

Copilot's review at `ac764dbd` carries exactly one finding, severity High: *routine `review-lane-repin` advances can leave `lockstep.status` and the test literal stale, so the next advance would have the contract reporting `converged` while xFactory sits on the old pin.*

**The premise is correct, and it was already in this diff** — appended `reason:` item (3) says this convergence *"IS FALSIFIABLE BY THIS REPOSITORY'S OWN AUTOMATION WITHIN THE HOUR"*. Measured at the source: `review_lane_repin.WRITABLE_PATHS` is `(PIN_FILE, SNAPSHOT_FILE, MERGE_MASTER_WORKFLOW, PYTEST_SUITE_WORKFLOW)`, within `PIN_FILE` it rewrites only regex-anchored pin sites, and **the string `lockstep` does not occur in that file at all** — so the lane cannot move this field even in principle.

**It does not argue for withholding `converged`, for three measured reasons.**

1. **The hazard is symmetric.** `diverged` is falsifiable by the same lane in the same way, and caught by nothing either — *"the assertion reads this file's own value, not the cross-repository fact"* (`7fd8fa5f`). Picking the value that is false today to guard against tomorrow is strictly worse.
2. **Today `diverged` is the false one.** Four measured sites name `b21f0100`, read at `cfe27de3`, two commits past the ceremony merge.
3. **The estate has already declared `converged` under exactly this regime.** `.github/workflows/review-lane-repin.yml` landed **2026-09-06** (`1897f282`, PR #715); the last `converged` declaration, `d8bdc58a`, is **2026-09-10** — four days later, lane live and auto-merge armed.

**And rather than leave the answer in a review thread, `016d055c` records the REMEDY SHAPE in the field itself**, because this file is where this repository keeps records: (a) widen the lane's writable set to this field and its test literal so an advance leaving the aggregation behind writes `diverged` in the same proposed diff; or **(b) make the cross-repository fact assertable at all** — nothing today reads xFactory's three surfaces and compares them to this value, which is why a false `status` survives in *either* direction until a human notices, and why 2026-09-18's survived eleven days. **(b) is the better fix**, because (a) still leaves this file's truth depending on a lane remembering to write it. Both are behaviour changes to a realized capability (`mirror-floor-regeneration-automation`) and go through OpenSpec — which is exactly why neither rides here, and is the same disposition `7fd8fa5f` recorded in this same field: *"Narrowing that clause is the ratifier's act, not this diff's."*

## Path class and landing

**No `openspec/changes/` path is touched, and the README "OpenSpec Records" block is not touched** — `specs/` is the Speckit feature tree. Rule 6's landing window therefore does not apply and this is a **plain gate**. `/contracts/review-lane-pin.yaml` is routed to @brettheap by CODEOWNERS and is a never-clearable floor member, so the merge-master lane will park it by design; the human gate is the landing act. **The holder lands this, not this actor.**


Lane: openxfactory-4
Co-Authored-By: Claude Fable 5.1 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants