This section defines the note, its commitment and its extracted commitment, and proves their hiding and binding; it constructs the derivation of all randomness of a created note from one seed under the lead byte , and defines the Action and the bundle as units of a transaction.
The zatoshi is the smallest unit of value; one ZEC, the unit of the native currency of Zcash, is zatoshi (protocol specification, §“Shielded Pools and Notes” and §“Mainnet and Testnet”). Every value in this volume, note values included, is an integer number of zatoshi.
A note is a tuple , where
the address of the recipient, of the type constructed in §3.3: a diversifier and a transmission key ;
the value , in zatoshi;
the elements and ;
the commitment trapdoor
(protocol specification, §“Shielded Pools and Notes”; the lengths and are those of §“Constants”). The specification types as an integer in (§“Commitment”). This volume types it in , because every derivation of yields a reduced value and acts only as the scalar of , which depends on modulo alone; this typing makes the binding of Proposition 4.5 a statement about notes. For a created note, and are derived from its note seed, for an Ironwood-pool note in §4.3, and is the nullifier of the note consumed in the same Action, a rule constructed in “Nullifier chaining” (§6.3).
A note is never published. A transaction that creates a note publishes its extracted note commitment (Definition 4.4) and a ciphertext of its note plaintext for the recipient, constructed in “Encryption to the recipient” (§10.2) (protocol specification, §“Note Commitments” and §“Sending Notes (Orchard)”). Of the fields of a created note, only appears on chain in the clear: it equals the nullifier that the same Action publishes for its consumed note (“Nullifier chaining”, §6.3). This representation of value serves requirement R1 of §1.4; Propositions 4.5 and 4.8 state what the commitment hides.
The address and the value are the content of the note, its recipient and its amount; the trapdoor randomises its commitment; the elements and , which also enter the commitment, are the note-specific inputs of its nullifier, constructed in “The nullifier” (§6.1).
For a note let (§3.3) and
with and read as integers in ; the string has the fixed length of Table 4. With , the note commitment of is
By the routing of §2.4, with the hash point and the blinding base
the commitment is if , and otherwise. The extracted note commitment is (§2.1). The specification’s takes the five encoded fields as separate arguments, in the order of their encodings in (protocol specification, §“Sinsemilla commitments”, §“Sending Notes (Orchard)” and §“Coordinate Extractor for Pallas”).
A sender never publishes : it redraws the note seed (step (vi) of the derivation of §4.3). The extracted commitment is the value an Action publishes for its created note, and the leaf of that note in the pool’s note commitment tree of “The Merkle hash and the tree” (§5.1), whose nodes are elements of .
The blinding base is not : the protocol specification, §“Sinsemilla commitments”, states that is perfectly hiding for a uniform trapdoor, for every domain, which holds only for a blinding base other than (as for , §3.2).
Perfect hiding. Let be uniform on . For every note content whose message has hash point , the commitment is uniform on . Hence the distributions of and of do not depend on , and is perfectly hiding on messages without a output, in the sense of the Crypto Guide’s Definition “Hiding game and hiding” (§“Hiding and binding”).
Binding of the extracted commitment. Under Assumptions 2.22 and 2.8, no efficient algorithm outputs, except with negligible probability, two notes with . In particular two distinct notes share no note commitment other than . With Proposition 2.24(iii), which excludes messages with output , part (b) gives computational binding in the sense of the Crypto Guide’s Definition “Binding game and binding” (same section), with the note content as the message and as the randomness, stated for notes and for the extracted value.
Proposition 4.8 states hiding for the trapdoor that a sender derives.
(a) This is Lemma 2.26(i) for the domain and the message length , whose hypothesis holds by the paragraph above; the value is a fixed function of . Equal distributions for every pair of contents without a output are perfect hiding by the Crypto Guide’s Proposition “Distributional characterisation of hiding” (§“Hiding and binding”).
(b) Step 1 reduces distinct notes to distinct openings. The map is injective: the string concatenates fields of fixed lengths; the star encoding is injective (§2.1); the encoding is injective on ; and the encoding is injective on the representatives of , since (§2.1). The map is therefore injective except on pairs of notes with and . Let and be the values of at and at the corresponding input for , distinct inputs because is injective. If , equal diversified bases give ; otherwise or . Each is a non-trivial relation among values of on distinct inputs, which the lemma on relations among fixed generators (§2.4) excludes except with negligible probability.
Step 2 treats distinct openings. Let . The lifting maps only to , so and are points, and by Lemma 2.4 or . The pairs and are openings of the instance in . By Proposition 2.24(ii), outputs with , or with and , have negligible probability (in the opposite case the relation in its proof has coefficient on the hash base, for a message of chunks). In the remaining case and , and outside the event of Step 1 the openings differ, so in ; then , impossible for in a group of prime order . A note commitment other than shared by gives equal extracted commitments other than , which proves the particular case. □
A created note reaches its recipient as a note plaintext, the byte string constructed in “The note plaintext” (§10.1) that the sender encrypts. Its first byte, the lead byte, names the format of the plaintext and selects the derivation of the note’s randomness. The sender draws one note seed , a uniform -byte string, the key type of (§2.3), which the plaintext carries. The values and of the note and the ephemeral secret key of “Encryption to the recipient” (§10.2) are all derived from it (protocol specification, §“Note Plaintexts and Memo Fields” and §“Sending Notes (Orchard)”).
The input is an address , a value and . Let and . For a point the -byte string equals (§2.1). The sender
checks that ;
draws uniformly from the -byte strings;
derives , and returns to (ii) if ;
derives ;
derives , where
a string of bytes;
computes of the note by Definition 4.4, and returns to (ii) if .
The output is the note , its seed and (protocol specification, §“Sending Notes (Orchard)”; ZIP 2005, “Changes to the Protocol Specification”, §4.7.3).
The order is forced: the string contains , so is derived after . The strings and in are those of the message , packed into bytes, so is a function of and of every committed field . The leading bytes , and are rows of Table 3.
An Ironwood-pool note has the type of Definition “Note” (§4.1) and is committed by the same (Definition 4.4). Every note created by an Ironwood-pool Action, a dummy created note included, has a plaintext with lead byte and the derivations above; no note created by an Orchard-pool Action does. This is the only note-level distinction between the two pools (ZIP 229, “Transaction Format”; ZIP 258, “ZIP 2005 activation”).
An adversary chooses two tuples , , of the input type of the construction above, with . The challenger draws a uniform bit , runs steps (ii) to (vi) of the construction on tuple , and returns , the note commitment of the note it computes and its ; the adversary receives no other function of (the ciphertext that carries is treated in Theorem 12.12). It outputs a bit . Let the number bound the advantage against Assumption 2.12 of each algorithm built from the adversary in the proof, each of which queries on three inputs with pairwise distinct leading bytes; let bound the distance of from uniform (§2.3); and let be the largest, over , of the sum of two probabilities that one pass through steps (ii) to (vi) on tuple returns to step (ii), one with as specified and one with its three outputs replaced by independent uniform strings. Then
and and are negligible under Assumptions 2.12, 2.22 and 2.8. The same bound holds with in place of .
Fix the adversary’s tuples. One pass through steps (ii) to (vi) with a fresh is a trial; its output is , and it is accepted, event , when and , since exactly when . Trials are independent and identically distributed, and the challenger returns the output of the first accepted one; so its answer on tuple is distributed as the output of one trial conditioned on . For a random variable and an event with , the statistical distance between and conditioned on is at most : for every set ,
and both terms lie in .
Hybrid 1 replaces the outputs of on , and by independent uniform , so that , and . The three inputs have distinct leading bytes, the input is chosen after the answer that determines , and is used only as a key of . By Lemma 2.15 (Assumption 2.12), the probability that any efficient test outputs on the trial’s output changes by at most . Hybrid 2 replaces by a uniform element of , independent of all else, at statistical cost . The event does not involve , so its probability is the same in both hybrids.
In Hybrid 2 the values and are independent, is the intersection of an event on and an event on , and is uniform and independent of both. Conditioned on , therefore, and is uniform on by Proposition 4.5(a), independently of , and is distributed as conditioned on being non-zero. This distribution does not depend on .
For each , the adversary’s output probability on differs from that on by at most the rejection probability of a trial as specified ( against ), plus ( against its form in Hybrid 2), plus the rejection probability in Hybrid 2, which equals that with uniform strings (the unconditioned form in Hybrid 2 against ). The two rejection probabilities sum to at most . Adding the bounds for and gives the stated bound. For , an adversary against is one against that first applies the fixed map .
Negligibility. With uniform strings, has probability at most . The event has the probability with which an efficient algorithm finds a message of hash point : the algorithm that runs the adversary’s choice of tuples, draws , and outputs for tuple with . That probability is negligible by Proposition 2.24(iii) under Assumptions 2.22 and 2.8. Rejection is efficiently decidable from the three outputs of , so the rejection probability as specified exceeds that with uniform strings by at most , negligible under Assumption 2.12. □
Because is a hash of and of every committed field, Ironwood-pool notes are recoverable in the sense of ZIP 2005. That ZIP proposes, with details subject to change, a Recovery Protocol for recovering Ironwood-pool funds if the Orchard protocol must be disabled because discrete logarithms become computable; a recovery protocol whose statement recomputes by this derivation can bind a note even against an adversary able to compute discrete logarithms (ZIP 2005, Abstract; Rationale, “Proposed Recovery Protocol” and “Repairing note commitments”). Against such an adversary alone is not binding: the discrete-logarithm relations between its bases give a linear equation over with several solutions, hence two distinct notes that open one commitment (ZIP 2005, Rationale, “Attacks against binding of note commitments”). What the deployed protocol checks of the derivation is stated with the Action statement, defined in “The Action statement” (§9.2).
The specification defines, for each pool, the set of lead bytes allowed in a note plaintext of that pool. For every transaction that contains Actions of the pool, the set is for the Ironwood pool and for the Orchard pool (protocol specification, §“Note Plaintexts and Memo Fields”; ZIP 2005, “Changes to the Protocol Specification”, §3.2.1; ZIP 258, “ZIP 2005 activation”). The lead byte travels encrypted, and each decrypting party enforces the rule: decryption with an incoming viewing key, by the recipient, and decryption with an outgoing viewing key, by its holder, both return when the lead byte is not allowed (§“Decryption using an Incoming Viewing Key (Sapling and Orchard)” and §“Decryption using an Outgoing Viewing Key (Sapling and Orchard)”). For an Ironwood-pool output this is check (i) of the acceptance procedure of “Trial decryption and note acceptance” (§10.4). The one consensus check of the lead byte is stated in “Chain state and pool rules” (§11.4).
An Action of a pool consumes one note and creates one note of that pool; it is the specification’s Action transfer, and every Action has both sides (protocol specification, §“Action Transfers and their Descriptions”). Its public data carry the extracted commitment of the created note (Definition 4.4), the nullifier of the consumed note (“The nullifier”, §6.1), a randomised validating key with a spend-authorisation signature (“Randomised validating keys”, §7.2), a net value commitment (“Value commitments”, §8.1), and the ciphertexts of “Encryption to the recipient” (§10.2). “Action descriptions and bundles” (§11.1) assembles them and redefines neither the Action nor the bundle. The relation that each Action must satisfy is the Action statement, defined in “The Action statement” (§9.2).
Every Action has one consumed and one created note, so that its public fields are the same whether a side is real or not; a side that a payment does not use carries a dummy note, a note of value . A dummy consumed note is built as follows (protocol specification, §“Dummy Notes (Orchard)”; ZIP 2005, “Changes to the Protocol Specification”, §4.8.3):
set , draw uniformly, and set for a uniform point of ;
derive and under the lead byte chosen as for a created note of the pool (ZIP 2005, “Changes to the Protocol Specification”, §4.8.3); in the Ironwood pool the lead byte is and the derivations are steps (iv) and (v) of §4.3;
compute by Definition 4.4, and repeat from the draw of with a fresh seed if .
Its nullifier is computed as for any note (“The nullifier”, §6.1). For step (iii) the two sources differ: the specification’s section chooses the lead byte with the pool fixed to the Orchard pool, which gives also in the Ironwood pool, whereas ZIP 2005, §4.8.3, makes the choice identical for dummy and non-dummy notes. The volume follows the ZIP. No condition of the Action statement checks the derivation of (Definition 9.2, Remark “What the statement does not check”).
A dummy created note is a created note of value , built as any created note; in the Ironwood pool it therefore carries lead byte . Its address depends on the flag of the bundle (“Bundle flags”, §9.1).
When , the dummy created note goes to a random address (protocol specification, §“Dummy Notes (Orchard)”).
When , as in every Orchard-pool bundle, condition A10 of Definition 9.2 places the note that an Action creates at the expanded receiver, defined in “Bundle flags”, of the note that the same Action consumes. A dummy created note then goes to the expanded receiver of that consumed note, real or dummy. In the Orchard pool, beside a real consumed note, the sender fills the component of the note ciphertext of the dummy created note (“Encryption to the recipient”, §10.2) with random bytes, not with an encryption of its plaintext (ZIP 326, “Fabricated same-address outputs and randomized note ciphertexts”). A dummy consumed note beside a real created note lies at the expanded receiver of that created note: in place of step (i) it takes the created note’s address and the key components of the key from which that address derives, and the Action’s spend-authorisation signature requires that key’s (Remark “Meaning of A10”, §9.2). A fresh key as in step (i) remains admissible when both sides of the Action are dummies at its address.
That the public data do not reveal which sides of an Action are real is part of Theorem 12.12 (§12.4).
The bundle of a pool in a transaction, which ZIP 229 calls the pool’s component, is the sequence of that pool’s Actions in the transaction together with the bundle-level data that later sections attach: one anchor (“Anchors”, §5.2), one balancing value (“The balancing value”, §8.2), one binding signature (“The binding signature”, §8.3), the flags (“Bundle flags”, §9.1) and one proof for all its Actions (“The Action circuit and the Halo 2 proof”, §9.3). A transaction carries at most one bundle per pool (ZIP 229, “Transaction Format”).