Skip to content

ZIP 244, ZIP 246: Disambiguate scope of BLAKE2b-256 over per-input data.#1291

Draft
nuttycom wants to merge 1 commit into
zcash:mainfrom
nuttycom:zip-244-246-blake2b
Draft

ZIP 244, ZIP 246: Disambiguate scope of BLAKE2b-256 over per-input data.#1291
nuttycom wants to merge 1 commit into
zcash:mainfrom
nuttycom:zip-244-246-blake2b

Conversation

@nuttycom

Copy link
Copy Markdown
Contributor

Closes #1082.

In `transparent_auth_digest` (ZIP 246), `sapling_auth_digest` and
`transparent_scripts_digest` (ZIP 244), the existing wording
"BLAKE2b-256 hash of for each " was ambiguous: it could be read
as either a single hash over the concatenation of all values, or as
the concatenation of per- hashes. The intended reading (consistent
with the existing empty-case definition `BLAKE2b-256(..., [])` which
yields a single 32-byte output) is a single hash over the concatenation.
Each site is rephrased to make the concatenation explicit and to
specify transaction-order iteration.

The "For each X, the following elements are included in the hash"
pattern (T.3a.ii, T.3b.i/ii/iii, T.4a/b/c, T.5a, etc.) was left
untouched: that wording references a previously-named single hash and
is materially less ambiguous; broader cleanup of that pattern is a
separate concern.

Filed with Claude Code assistance.

In `transparent_auth_digest` (ZIP 246), `sapling_auth_digest` and
`transparent_scripts_digest` (ZIP 244), the existing wording
"BLAKE2b-256 hash of <X> for each <Y>" was ambiguous: it could be read
as either a single hash over the concatenation of all <X> values, or as
the concatenation of per-<Y> hashes. The intended reading (consistent
with the existing empty-case definition `BLAKE2b-256(..., [])` which
yields a single 32-byte output) is a single hash over the concatenation.
Reword each site to make the concatenation explicit and to specify
transaction-order iteration.

Closes zcash#1082.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.

[ZIP 244, 246] Ambiguous scope for "BLAKE2b-256 hash of"

1 participant