Skip to content

docs: paper-conformance rule + resolve #105/#106 via bounded 6-confirmation finality - #107

Merged
TaprootFreak merged 4 commits into
developfrom
docs/paper-conformance-rule
Jul 18, 2026
Merged

docs: paper-conformance rule + resolve #105/#106 via bounded 6-confirmation finality#107
TaprootFreak merged 4 commits into
developfrom
docs/paper-conformance-rule

Conversation

@TaprootFreak

@TaprootFreak TaprootFreak commented Jul 18, 2026

Copy link
Copy Markdown
Contributor

Paper-conformance rule + resolution of #105 and #106

Two changes, both under the new hard project rule.

1. The paper-conformance rule (CONTRIBUTING.md)

zkCoins either conforms to its source works (the zkCoins concept and the Shielded CSV construction), or every deviation is justified in the spec itself — explicitly, completely, and rigorously. A load-bearing deviation does not inherit the papers' proofs and must carry its own security argument; until it does, the spec must not call it a "faithful port" or an "exact paper-model" construction.

2. Resolve #105 and #106 — bounded 6-confirmation finality

The spec previously claimed reorgs of any depth are survivable via a conditional-NAV no-op (an account proves a null transition when a dependency is orphaned). That no-op has no satisfiable witness in the circuit — clause 1 is an unconditional prefix(prev.nav, w.nav) with no DistinctElement/no-op branch (#105) — and the SMT prefix relation deliberately departs from the paper's ToS accumulator (#106).

Per the project directive, v1 does not build a novel no-op. It adopts a hard finality bound (spec §3.9):

  • 6 confirmations = final (receive-side: a receiver MUST NOT credit until final).
  • Reorgs of ≤5 blocks are absorbed by canonical replay; nothing final depends on a non-final nullifier, so no account is stranded. Building on a pending dependency stays a wallet liveness choice (§6.3).
  • A reorg of ≥6 blocks MAY break zkCoins — an explicit, accepted v1 limitation.

Registered as a deliberate deviation from Shielded CSV (paper-deviation analysis D-16); risks.md, the implementation mandate (D12) and the remediation plan are aligned. The circuit soundness (clause 1 predecessor-anchoring, first-occurrence) is untouched.

Closes #105
Closes #106

…ations

Hard project rule (CONTRIBUTING): conform to the source works (zkCoins gist,
Shielded CSV) or justify every deviation explicitly, completely, and
rigorously in the spec; a load-bearing deviation must not be called a
'faithful port' until it carries its own security argument.

Register two deviations verified verbatim against the paper (full text):
- conditional-NAV no-op is unsatisfiable under §2.1 clause 1 (no DistinctElement
  branch) — arbitrary-depth reorg recovery does not hold as written (#105);
- the §3.7 accumulator prefix relation is an unordered SMT submap, not the
  paper's ordered ToS tuple-prefix + DistinctElement (#106).
…ntradiction

Replace the unsatisfiable conditional-NAV no-op / arbitrary-depth reorg
survivability claim with a hard 6-confirmation finality bound: reorgs of up
to 5 blocks are absorbed by canonical replay, and a reorg of 6 or more blocks
may break zkCoins as an explicit, accepted v1 limitation. The bound is
receive-side (a receiver must not credit until final); building on a pending
dependency stays a wallet liveness choice. Register the deviation from
Shielded CSV in the paper-deviation analysis and align risks, the
implementation mandate, and the remediation plan.
@TaprootFreak TaprootFreak changed the title docs: paper-conformance rule + flag two verified paper deviations (#105, #106) docs: paper-conformance rule + resolve #105/#106 via bounded 6-confirmation finality Jul 18, 2026
@TaprootFreak
TaprootFreak marked this pull request as ready for review July 18, 2026 15:11
…tion gates

Five sections of the remediation plan still mandated the retired
conditional-NAV no-op / arbitrary-depth recovery as a normative gate:
the section 1.3 verification MUST-list, the section 7 security-package
deliverables, the Gate B conformance tests, and two section 9 edit-map
rows. Bring them into line with F-03, section 3.2 and the release matrix,
and add the not-yet-final qualifier to the section 3.9 re-evaluation rule.
@TaprootFreak

Copy link
Copy Markdown
Contributor Author

Readiness: this PR went through 2 review passes to zero defects (independent conformity + logic reviews). Pass 1 raised three consistency nits — a house-style **Risk:** lead on the reorg-finality section, the #106 mitigation reworded as resolved-by-deviation, and the D-16 deviation status corrected GREENAMBER to match the register legend (commit 0328caf); pass 2 found no defects. Docs build verified green.

@TaprootFreak
TaprootFreak merged commit 45399da into develop Jul 18, 2026
5 checks passed
TaprootFreak added a commit that referenced this pull request Jul 20, 2026
Collapses the IssuanceTerms_v2 auditable-supply-cap work (genesis-anchored
single mint; cap_total + terms_salt bound into asset_id via the AssetIdV2
tag; fail-closed issuance-version dispatch in clause 3) onto the current
develop after #89, #102 and #107 merged. Conflict resolution: the asset_terms
transport paragraph takes the version-dependent form, the mint first-occurrence
comment its expanded wording; develop's serialize(Coin) paragraph and the
6-confirmation finality directive are preserved unchanged.

Original v2 design by joshuakrueger-dfx; fail-closed dispatch fix follows.
TaprootFreak added a commit that referenced this pull request Jul 20, 2026
TaprootFreak added a commit that referenced this pull request Jul 20, 2026
…#100)

* spec: rebase the IssuanceTerms_v2 supply cap onto develop

Collapses the IssuanceTerms_v2 auditable-supply-cap work (genesis-anchored
single mint; cap_total + terms_salt bound into asset_id via the AssetIdV2
tag; fail-closed issuance-version dispatch in clause 3) onto the current
develop after #89, #102 and #107 merged. Conflict resolution: the asset_terms
transport paragraph takes the version-dependent form, the mint first-occurrence
comment its expanded wording; develop's serialize(Coin) paragraph and the
6-confirmation finality directive are preserved unchanged.

Original v2 design by joshuakrueger-dfx; fail-closed dispatch fix follows.

* spec: fix v2 review nits (v1 clause-a branch scope, v1-and-v2 version dispatch)

* spec: apply pr-ready review consistency fixes (v1 clause-a branch scope, clause-8 v2 self-mint carve-out, risks mitigation tense, first-occurrence naming)

* spec: complete the v2 self-mint deferral across balances (clause 7) and the §501 invariant, and name clause 7 in clause (g)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant