The Zcash ArboretumIronwood Guide PDF

6 Nullifiers

This section constructs the nullifier of a note, the nullifier sets that consensus maintains per pool, and the rule that makes the nullifier of each consumed note the element ρ of the note created in the same Action. It proves two properties of the construction: uniqueness, from discrete logarithms on Pallas with 𝖦𝗋𝗈𝗎𝗉𝖧𝖺𝗌𝗁 modelled as a random oracle; and, for keys generated with 𝗎𝗌𝖾⁢_⁢𝗊𝗌𝗄=𝖿𝖺𝗅𝗌𝖾, unlinkability, from these two assumptions, the pseudorandomness of Poseidon and of PRF expansion, and the joint hiding of the viewing keys. It also states what each key tier can compute from nullifiers.

6.1 The nullifier

Requirement R3 of “Requirements on a shielded payment” (§1.4) excludes a second consumption of a note without a public list of consumed notes. Each note therefore determines a nullifier, a tag published when the note is consumed, and a verifier (§1.2) rejects a nullifier already in the nullifier set of its pool (§6.2). The construction must make the nullifier

  1. (a)

    deterministic: a function of the note and of the nullifier deriving key 𝗇𝗄 of the key that owns it, so that a second consumption publishes the same value; and

  2. (b)

    unlinkable: to a party without 𝗇𝗄, the published value reveals nothing about the note’s commitment or address.

Construction 6.1 (Nullifier PRF).

Let f:𝔽p𝖯𝖺𝗅𝗅𝖺𝗌3→𝔽p𝖯𝖺𝗅𝗅𝖺𝗌3 be the Poseidon permutation of width t=3 over the Pallas base field, used as a sponge of rate 2 and capacity 1, with S-box x↦x5, 8 full and 56 partial rounds (Crypto Guide, §“Arithmetisation-friendly hashing: Poseidon”, Constructions “The sponge construction” and “The Poseidon permutation”, Example “The Orchard Poseidon instance”). Its round constants and MDS matrix are those of the protocol specification, §“𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁 Function”, and are not reproduced. In constant-input-length mode the hash 𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁:𝔽p𝖯𝖺𝗅𝗅𝖺𝗌×𝔽p𝖯𝖺𝗅𝗅𝖺𝗌→𝔽p𝖯𝖺𝗅𝗅𝖺𝗌 is

𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁⁢(x,y):=π1⁢(f⁢(x,y,265)),

where π1 is the projection onto the first component; the capacity element 265 encodes the input length 2, so no padding is needed (same citations). The nullifier PRF is

𝖯𝖱𝖥𝗇𝖿𝖮𝗋𝖼𝗁𝖺𝗋𝖽:𝔽p𝖯𝖺𝗅𝗅𝖺𝗌×𝔽p𝖯𝖺𝗅𝗅𝖺𝗌→𝔽p𝖯𝖺𝗅𝗅𝖺𝗌,𝖯𝖱𝖥𝗇𝗄𝗇𝖿𝖮𝗋𝖼𝗁𝖺𝗋𝖽⁢(ρ):=𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁⁢(𝗇𝗄,ρ),

keyed by the nullifier deriving key 𝗇𝗄∈𝔽p𝖯𝖺𝗅𝗅𝖺𝗌 of “The spending key and the spend-side secrets” (§3.1; protocol specification, §“Pseudo Random Functions”).

Assumption 6.2 (Poseidon is a PRF).

For 𝗇𝗄 uniform on 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌, no efficient adversary with adaptive oracle access distinguishes ρ↦𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁⁢(𝗇𝗄,ρ) from a uniformly random function 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌→𝔽p𝖯𝖺𝗅𝗅𝖺𝗌, except with negligible advantage: this is the game of Definition “Pseudorandom function” (§2.3; Crypto Guide, §“Pseudorandom functions and permutations”) with key, input and output sets 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌. It is the security requirement that the protocol specification, §“Pseudo Random Functions”, places on 𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁 keyed by its first argument. Its status is cryptanalytic: it is supported by the analysis of the Poseidon round function (protocol specification, §“𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁 Function”, notes) and has no reduction to a standard problem (Crypto Guide, Example “The Orchard Poseidon instance”). Of the results of this section only Proposition 6.10 uses it; Proposition 6.8 uses no property of 𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁, and the volume proves no unlinkability result for nullifiers without this assumption.

Definition 6.3 (Nullifier).

Let K𝖮𝗋𝖼𝗁𝖺𝗋𝖽:=𝖦𝗋𝗈𝗎𝗉𝖧𝖺𝗌𝗁⁢(z.cash:Orchard,K), the nullifier base, a fixed generator of Table 2. For 𝗇𝗄,ρ,ψ∈𝔽p𝖯𝖺𝗅𝗅𝖺𝗌 and a point 𝖼𝗆∈ℰ⁢(𝔽p𝖯𝖺𝗅𝗅𝖺𝗌),

𝖣𝖾𝗋𝗂𝗏𝖾𝖭𝗎𝗅𝗅𝗂𝖿𝗂𝖾𝗋𝗇𝗄⁢(ρ,ψ,𝖼𝗆):=𝖤𝗑𝗍𝗋𝖺𝖼𝗍ℙ⁢([s]⁢K𝖮𝗋𝖼𝗁𝖺𝗋𝖽+𝖼𝗆)∈𝔽p𝖯𝖺𝗅𝗅𝖺𝗌,

where

s:=(𝖯𝖱𝖥𝗇𝗄𝗇𝖿𝖮𝗋𝖼𝗁𝖺𝗋𝖽⁢(ρ)+ψ)modp𝖯𝖺𝗅𝗅𝖺𝗌∈{0,…,p𝖯𝖺𝗅𝗅𝖺𝗌−1}:

the sum of the two field elements is taken as its representative in {0,…,p𝖯𝖺𝗅𝗅𝖺𝗌−1}, and that integer multiplies K𝖮𝗋𝖼𝗁𝖺𝗋𝖽. The nullifier of a note n=(𝖺𝖽𝖽𝗋,v,ρ,ψ,𝗋𝖼𝗆) whose note commitment 𝖼𝗆 (Definition 4.4) is not ⊥, under the nullifier deriving key 𝗇𝗄 of the key that owns 𝖺𝖽𝖽𝗋, is

𝗇𝖿:=𝖣𝖾𝗋𝗂𝗏𝖾𝖭𝗎𝗅𝗅𝗂𝖿𝗂𝖾𝗋𝗇𝗄⁢(ρ,ψ,𝖼𝗆)

(protocol specification, §“Computing ρ values and Nullifiers”).

Remark 6.4 (Reduction modulo p𝖯𝖺𝗅𝗅𝖺𝗌).

The protocol specification attaches two notes to the definition (§“Computing ρ values and Nullifiers”). First, the sum is reduced modulo p𝖯𝖺𝗅𝗅𝖺𝗌 intentionally, although the scalar field of the Pallas group is 𝔽p𝖵𝖾𝗌𝗍𝖺. Since p𝖯𝖺𝗅𝗅𝖺𝗌<p𝖵𝖾𝗌𝗍𝖺 (§2.1), the representative in {0,…,p𝖯𝖺𝗅𝗅𝖺𝗌−1} is a scalar without further reduction, by the injective reading 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌→𝔽p𝖵𝖾𝗌𝗍𝖺 of §2.1, and the multiplier of K𝖮𝗋𝖼𝗁𝖺𝗋𝖽 ranges over p𝖯𝖺𝗅𝗅𝖺𝗌 of the p𝖵𝖾𝗌𝗍𝖺 scalars. Second, the inputs ρ and ψ must be those of the note committed to by 𝖼𝗆.

Remark 6.5 (Determinism and masking).

For a fixed 𝗇𝗄 the nullifier is a function of the fields ρ and ψ of the note and of its commitment 𝖼𝗆, so a note has exactly one nullifier under the 𝗇𝗄 of its owner. That every accepted consumption of the note publishes this value is Lemma 12.5, proved in “Double-spend resistance” (§12.2) from the Action statement, defined in “The Action statement” (§9.2). The point [s]⁢K𝖮𝗋𝖼𝗁𝖺𝗋𝖽 is added to 𝖼𝗆 before extraction. For notes of one key with pairwise distinct ρ, the key generated with 𝗎𝗌𝖾⁢_⁢𝗊𝗌𝗄=𝖿𝖺𝗅𝗌𝖾, the multipliers are jointly pseudorandom to an efficient party that holds the incoming viewing key and 𝖺𝗄ℙ but not 𝗇𝗄, so the extracted values give it no usable information on the commitments or on the address; Proposition 6.10 states this exactly, under Assumption 6.2 and the further assumptions it names. The element ρ enters as the input of the PRF and ψ as an additive term of the multiplier. Both are fixed when the note is created: ρ by “Nullifier chaining” (§6.3), and ψ by the derivation of §4.3.

6.2 Nullifier sets

Each verifier maintains, for each shielded pool, a nullifier set, part of that pool’s treestate (“Anchors”, §5.2). Every Action publishes one nullifier, that of its consumed note, real or dummy (§4.4), and the nullifiers published by the Actions of valid transactions are inserted into the nullifier set of their pool (protocol specification, §“Nullifiers” and §“Nullifier Sets”). The consensus rule of §“Nullifier Sets” is that a nullifier must not repeat, either within a transaction or across transactions in a valid block chain; a nullifier is compared only with nullifiers of its own pool, so equal values in two pools do not repeat a nullifier (the specification treats the pools’ nullifiers as disjoint).

Both pools use the one derivation of Definition 6.3, with the same PRF and the same nullifier base: the nullifier construction belongs to the Orchard protocol, not to a pool (ZIP 229, Terminology). The Orchard pool and the Ironwood pool keep separate nullifier sets, as they keep separate note commitment trees, anchors and value pool balances (ZIP 229, Rationale, “Separate state”; protocol specification, §“Nullifier Sets”). The nullifier of an Ironwood-pool Action is inserted into, and checked against, the nullifier set of the Ironwood pool only.

Remark 6.6 (Pool locality).

Equal nullifier values in the two pools do not violate the consensus rule, so every uniqueness property derived from it holds within one pool. In particular the uniqueness of the elements ρ proved in “Double-spend resistance” (Corollary 12.7) is uniqueness within a pool, not across the two pools.

6.3 Nullifier chaining

Construction 6.7 (Chaining rule).

In every Action the sender sets the element ρ of the created note to the nullifier that the same Action publishes for its consumed note,

ρ𝗇𝖾𝗐:=𝗇𝖿𝗈𝗅𝖽∈𝔽p𝖯𝖺𝗅𝗅𝖺𝗌,

and encodes it as the 32-byte string 𝖨𝟤𝖫𝖤𝖮𝖲𝖯256⁢(ρ𝗇𝖾𝗐). When the Action consumes no real note, its consumed side is a dummy note (Definition “Dummy notes”, §4.4), and the nullifier of that dummy note is ρ𝗇𝖾𝗐 (protocol specification, §“Sending Notes (Orchard)”, §“Dummy Notes (Orchard)” and §“Faerie Gold attack and fix”).

Every Action has a consumed side (Definition “Action”, §4.4), so every note that an Action creates is constructed with ρ equal to the nullifier of that Action’s consumed note. The leaves that enter a pool’s note commitment tree are the extracted commitments of notes created by that pool’s Actions (“The Merkle hash and the tree”, §5.1), so the rule covers every note whose extracted commitment enters the tree. The consumed dummy note is not created by an Action: its ρ is 𝖤𝗑𝗍𝗋𝖺𝖼𝗍ℙ of a uniformly random point of the Pallas group (§4.4).

The derivations of §4.3 take the chained ρ as input: with ρ¯:=𝖨𝟤𝖫𝖤𝖮𝖲𝖯256⁢(ρ),

𝖾𝗌𝗄 =ToScalar⁢(𝖯𝖱𝖥𝖾𝗑𝗉𝖺𝗇𝖽𝗋𝗌𝖾𝖾𝖽⁢([𝟶⁢𝚡⁢𝟶𝟺]∥ρ¯)), ψ =ToBase⁢(𝖯𝖱𝖥𝖾𝗑𝗉𝖺𝗇𝖽𝗋𝗌𝖾𝖾𝖽⁢([𝟶⁢𝚡⁢𝟶𝟿]∥ρ¯)),

and 𝗋𝖼𝗆 is derived from the string 𝗉𝗋𝖾⁢_⁢𝗋𝖼𝗆, which contains ρ¯ and the encoding of ψ. Hence 𝖾𝗌𝗄 and ψ are functions of 𝗋𝗌𝖾𝖾𝖽 and of the nullifier that the note’s own Action publishes, and 𝗋𝖼𝗆 is a function of these and of the remaining note fields.

A Faerie Gold attack is one in which a sender creates several notes to one recipient that share a nullifier, so that only one of them can be spent (protocol specification, §“Faerie Gold attack and fix”). What a verifier can rely on, the uniqueness of the elements ρ within a pool and resistance to the Faerie Gold attack, is proved in “Double-spend resistance” (Corollary 12.7) from the nullifier-set rule and the Action statement, defined in “The Action statement” (§9.2). This subsection states the rule that an honest sender follows and draws no conclusion about accepted notes from it.

6.4 Nullifier uniqueness and unlinkability

Proposition 6.8 (Nullifier uniqueness).

Under Assumptions 2.22 and 2.8, no efficient adversary outputs, except with negligible probability, two notes n=(𝖺𝖽𝖽𝗋,v,ρ,ψ,𝗋𝖼𝗆) and n′=(𝖺𝖽𝖽𝗋′,v′,ρ′,ψ′,𝗋𝖼𝗆′) and two nullifier deriving keys 𝗇𝗄,𝗇𝗄′∈𝔽p𝖯𝖺𝗅𝗅𝖺𝗌, all of its choice, whose note commitments 𝖼𝗆 and 𝖼𝗆′ are not ⊥ and satisfy 𝖼𝗆≠𝖼𝗆′ and

𝖣𝖾𝗋𝗂𝗏𝖾𝖭𝗎𝗅𝗅𝗂𝖿𝗂𝖾𝗋𝗇𝗄⁢(ρ,ψ,𝖼𝗆)=𝖣𝖾𝗋𝗂𝗏𝖾𝖭𝗎𝗅𝗅𝗂𝖿𝗂𝖾𝗋𝗇𝗄′⁢(ρ′,ψ′,𝖼𝗆′).

The adversary may hold every nullifier deriving key, and 𝗇𝗄=𝗇𝗄′ and ρ=ρ′ are admitted. Since two distinct notes have distinct commitments except with negligible probability (Proposition 4.5(b)), the same holds for two distinct notes in place of two distinct commitments.

Proof.

The adversary supplies both openings, so no knowledge extraction is used. Let its output satisfy the conditions, and write

K :=K𝖮𝗋𝖼𝗁𝖺𝗋𝖽,
Q :=Q⁢(z.cash:Orchard-NoteCommit-M),
HD :=𝖦𝗋𝗈𝗎𝗉𝖧𝖺𝗌𝗁⁢(z.cash:Orchard-NoteCommit-r,ε)

for the nullifier base and for the hash base and the blinding base of 𝖭𝗈𝗍𝖾𝖢𝗈𝗆𝗆𝗂𝗍 (Definition 4.4). A reduction that runs the adversary computes s:=(𝖯𝖱𝖥𝗇𝗄𝗇𝖿𝖮𝗋𝖼𝗁𝖺𝗋𝖽⁢(ρ)+ψ)modp𝖯𝖺𝗅𝗅𝖺𝗌 and s′ likewise; the pieces m=(m1,…,m109) and m′ of the messages M⁢(n) and M⁢(n′), which have 109 chunks of k=10 bits (Table 4); and 𝗋𝖼𝗆, 𝗋𝖼𝗆′. Every coefficient below is therefore known to it, the PRF outputs included, and no property of 𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁 is used.

Equal nullifiers are equal extracted coordinates, so by Lemma 2.4

[s]⁢K+𝖼𝗆=θ⁢([s′]⁢K+𝖼𝗆′)for some ⁢θ∈{1,−1}.

Since 𝖼𝗆≠⊥, its hash point is not ⊥, and by the unrolled form (1) of the proof of Proposition 2.24,

𝖼𝗆=[2109]⁢Q+∑j=02k−1[χj⁢(m)]⁢S⁢(j)+[𝗋𝖼𝗆]⁢HD,χj⁢(m)=∑i=11092109−i⁢δmi,j,

and likewise for 𝖼𝗆′. Substituting gives, with coefficients in 𝔽p𝖵𝖾𝗌𝗍𝖺 and s, s′ read as scalars,

[s−θ⁢s′]⁢K+[(1−θ)⁢ 2109]⁢Q+∑j[χj⁢(m)−θ⁢χj⁢(m′)]⁢S⁢(j)+[𝗋𝖼𝗆−θ⁢𝗋𝖼𝗆′]⁢HD=𝒪. (3)

The relation is non-trivial in each case.

  • •

    If θ=−1, the coefficient of Q is 2110, non-zero modulo p𝖵𝖾𝗌𝗍𝖺 because 0<2110<2253≤(p𝖵𝖾𝗌𝗍𝖺−1)/2.

  • •

    If θ=1 and M⁢(n)≠M⁢(n′), then m≠m′, and χ⁢(m)≠χ⁢(m′) modulo p𝖵𝖾𝗌𝗍𝖺 by step (1) of the proof of Proposition 2.24 (109≤c=253); some coefficient of an S⁢(j) is non-zero.

  • •

    If θ=1 and M⁢(n)=M⁢(n′), then 𝗋𝖼𝗆≠𝗋𝖼𝗆′, since equal messages and equal trapdoors give 𝖼𝗆=𝖼𝗆′; the coefficient of HD is non-zero.

The points K, Q, S⁢(0),…,S⁢(2k−1) and HD are values of 𝖦𝗋𝗈𝗎𝗉𝖧𝖺𝗌𝗁 on pairwise distinct inputs (Table 2). The reduction outputs these inputs with the coefficients of (3), a non-trivial relation with known coefficients. By the lemma on relations among fixed generators (§2.4), the reduction behind Proposition 2.24, this happens with negligible probability under Assumptions 2.22 and 2.8. The specification records that its Sinsemilla collision argument extends to additional terms with independent bases for this purpose (protocol specification, §“Sinsemilla Hash Function”, Security argument, note; §“Faerie Gold attack and fix”).

For distinct notes whose commitments are not ⊥, equal commitments have negligible probability by Proposition 4.5(b), and distinct commitments are the case above. □

Remark 6.9 (Scope of Proposition 6.8). #

The proposition uses no pseudorandomness of 𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁, and none could be used: the adversary holds the PRF keys, and the reduction knows every coefficient. It does not require distinct elements ρ, which the specification’s security requirement assumes (§“Computing ρ values and Nullifiers”). Two notes with equal commitments are equal except with negligible probability (Proposition 4.5(b)) and so have equal nullifiers under one 𝗇𝗄. Excluding equal commitments among the notes of a pool is the role of the chaining rule of §6.3, as Corollary 12.7 proves.

Proposition 6.10 (Nullifier unlinkability).

Let a key be generated with 𝗎𝗌𝖾⁢_⁢𝗊𝗌𝗄=𝖿𝖺𝗅𝗌𝖾 from a uniform spending key, as in §3.1 and §3.2, with nullifier deriving key 𝗇𝗄. An adversary receives the incoming viewing key (𝖽𝗄,𝗂𝗏𝗄) and the point 𝖺𝗄ℙ of the key, but not 𝗇𝗄. It then submits, adaptively, notes ni=(𝖺𝖽𝖽𝗋i,vi,ρi,ψi,𝗋𝖼𝗆i), 1≤i≤q, of its choice, with pairwise distinct ρi and note commitments 𝖼𝗆i≠⊥, and after each submission receives an answer:

  • •

    in the real game, 𝗇𝖿i:=𝖣𝖾𝗋𝗂𝗏𝖾𝖭𝗎𝗅𝗅𝗂𝖿𝗂𝖾𝗋𝗇𝗄⁢(ρi,ψi,𝖼𝗆i);

  • •

    in the ideal game, 𝖤𝗑𝗍𝗋𝖺𝖼𝗍ℙ⁢([ui]⁢K𝖮𝗋𝖼𝗁𝖺𝗋𝖽+𝖼𝗆i) for ui uniform on 𝔽p𝖵𝖾𝗌𝗍𝖺, independent of each other and of all else.

It outputs a bit. Let δ:=(p𝖵𝖾𝗌𝗍𝖺−p𝖯𝖺𝗅𝗅𝖺𝗌)/p𝖵𝖾𝗌𝗍𝖺, which is below 2−167, the statistical distance between the uniform distribution on {0,…,p𝖯𝖺𝗅𝗅𝖺𝗌−1}, read in 𝔽p𝖵𝖾𝗌𝗍𝖺, and the uniform distribution on 𝔽p𝖵𝖾𝗌𝗍𝖺. Then the difference of the probabilities that it outputs 1 in the two games is at most

2⁢(ϵ𝗄𝖾𝗒+ϵ𝖾𝗑𝗉𝖺𝗇𝖽+3⋅2−257+ϵ𝗏𝗄)+ϵ𝖯𝗈𝗌+q⁢δ,

where ϵ𝖾𝗑𝗉𝖺𝗇𝖽, ϵ𝗏𝗄 and ϵ𝖯𝗈𝗌 are the largest advantages against Assumptions 2.12 (through Lemma 2.15), 3.13 and 6.2 of the algorithms built from the adversary in the proof, and ϵ𝗄𝖾𝗒 is the probability that a single draw of key generation from a uniform spending key is rejected plus the probability that 𝖺𝗌𝗄=0 or M^=⊥ for independent uniform (𝖺𝗌𝗄,𝗇𝗄), with M^ the hash point of 𝖢𝗈𝗆𝗆𝗂𝗍𝗂𝗏𝗄 on (𝖺𝗄,𝗇𝗄) (§3.2). The term ϵ𝗄𝖾𝗒 is negligible under Assumptions 2.12, 2.22 and 2.8 (Lemma “Rejection in key generation”, §3.2); the bound is therefore negligible for every efficient adversary, whose number q of queries is polynomial, under these assumptions and Assumptions 3.13 and 6.2. When K𝖮𝗋𝖼𝗁𝖺𝗋𝖽≠𝒪, the point [ui]⁢K𝖮𝗋𝖼𝗁𝖺𝗋𝖽+𝖼𝗆i is uniform on ℰ⁢(𝔽p𝖯𝖺𝗅𝗅𝖺𝗌) whatever 𝖼𝗆i is, so the ideal answers are independent of the notes and of each other; in the model of Assumption 2.8, K𝖮𝗋𝖼𝗁𝖺𝗋𝖽=𝒪 has probability 1/p𝖵𝖾𝗌𝗍𝖺.

Proof.

Write K:=K𝖮𝗋𝖼𝗁𝖺𝗋𝖽. The proof passes from the real game H0 through hybrid games H1,…,H5; each hop changes the probability of the output 1 by at most the amount stated (Crypto Guide, §“The hybrid argument”, Lemma “Hybrid lemma”), and each reduction runs the adversary and the rest of the game.

Hybrid H1: idealised key. The key is generated by a single draw from a uniform 𝗌𝗄, without rejection, at the cost of the probability that the draw is rejected (Lemma “Rejection in key generation”, §3.2). Then (𝖺𝗌𝗄,𝗇𝗄,𝗋𝗂𝗏𝗄) is replaced by independent uniform elements of 𝔽p𝖵𝖾𝗌𝗍𝖺, 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌 and 𝔽p𝖵𝖾𝗌𝗍𝖺, from which the other components are derived as in §3.1 and §3.2. By Lemma 2.15, this costs at most ϵ𝖾𝗑𝗉𝖺𝗇𝖽 plus the three reduction distances, each below 2−257 (§2.3): the three inputs of 𝖯𝖱𝖥𝖾𝗑𝗉𝖺𝗇𝖽𝗌𝗄 have distinct lead bytes, and the game is an efficient function of the triple, which derives 𝖺𝗄ℙ, 𝗂𝗏𝗄 and 𝖽𝗄, runs the adversary and answers each query with the nullifier under 𝗇𝗄.

Hybrid H2: joint hiding. When 𝖺𝗌𝗄≠0, the pair (𝗂𝗏𝗄,𝖽𝗄) is replaced by (𝖢𝗈𝗆𝗆𝗂𝗍𝗋𝗂𝗏𝗄′𝗂𝗏𝗄⁢(𝖺𝗄,𝗇𝗄),u), for 𝗋𝗂𝗏𝗄′ uniform on 𝔽p𝖵𝖾𝗌𝗍𝖺 and u a uniform 32-byte string, independent of all else. The cost is at most ϵ𝗏𝗄. The reduction for Assumption 3.13 draws 𝖺𝗌𝗄 and 𝗇𝗄 itself; for 𝖺𝗌𝗄≠0 the pair (𝖺𝗄,𝗇𝗄) lies in the domain of the assumption (§3.1). It receives a triple for that pair, passes its first two components to the adversary as 𝗂𝗏𝗄 and 𝖽𝗄, together with 𝖺𝗄ℙ, and answers every query with the nullifier under its own 𝗇𝗄. Giving 𝖺𝗄ℙ costs nothing, because after H1 the scalar 𝖺𝗌𝗄 is independent of (𝗇𝗄,𝗋𝗂𝗏𝗄) and the assumption holds for every fixed (𝖺𝗄,𝗇𝗄).

Hybrid H3: independent viewing keys. The pair (𝗂𝗏𝗄,𝖽𝗄) is replaced, whatever 𝖺𝗌𝗄 is, by (𝖤𝗑𝗍𝗋𝖺𝖼𝗍ℙ⁢(W),u) for a uniform point W and a uniform 32-byte string u, independent of all else. When 𝖺𝗌𝗄≠0 and the hash point M^ of the message LE255⁢(𝖺𝗄)∥LE255⁢(𝗇𝗄) is not ⊥, the commitment point M^+[𝗋𝗂𝗏𝗄′]⁢HD is uniform on ℰ⁢(𝔽p𝖯𝖺𝗅𝗅𝖺𝗌) by Lemma 2.26(i), its blinding base HD not being 𝒪 (§3.2), so the two games are identically distributed conditioned on that event, which depends on (𝖺𝗌𝗄,𝗇𝗄) only. The cost is at most the probability that 𝖺𝗌𝗄=0 or M^=⊥, the remaining part of ϵ𝗄𝖾𝗒. In H3 the key 𝗇𝗄 enters the game only through the answers: 𝖽𝗄, 𝗂𝗏𝗄 and 𝖺𝗄ℙ are independent of it.

Hybrid H4: random function. The function 𝖯𝖱𝖥𝗇𝗄𝗇𝖿𝖮𝗋𝖼𝗁𝖺𝗋𝖽 is replaced by a uniformly random function F:𝔽p𝖯𝖺𝗅𝗅𝖺𝗌→𝔽p𝖯𝖺𝗅𝗅𝖺𝗌. The cost is at most ϵ𝖯𝗈𝗌: the reduction for Assumption 6.2 runs H3 with its oracle in place of 𝖯𝖱𝖥𝗇𝗄𝗇𝖿𝖮𝗋𝖼𝗁𝖺𝗋𝖽, since 𝗇𝗄, uniform on 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌, is used nowhere else. In H4 the i-th answer is 𝖤𝗑𝗍𝗋𝖺𝖼𝗍ℙ⁢([si]⁢K+𝖼𝗆i) with si:=(F⁢(ρi)+ψi)modp𝖯𝖺𝗅𝗅𝖺𝗌. The ρi are pairwise distinct, so, with F sampled lazily, F⁢(ρi) is uniform on 𝔽p𝖯𝖺𝗅𝗅𝖺𝗌 and independent of everything the adversary has received when it submits ni. Translation by ψi is a bijection modulo p𝖯𝖺𝗅𝗅𝖺𝗌, so si is uniform on {0,…,p𝖯𝖺𝗅𝗅𝖺𝗌−1} and independent of that view, whatever ψi is.

Hybrid H5: uniform scalars. For i=1,…,q in turn, the scalar si, read in 𝔽p𝖵𝖾𝗌𝗍𝖺 (§2.1), is replaced by ui uniform on 𝔽p𝖵𝖾𝗌𝗍𝖺. The two distributions differ by 1/p𝖯𝖺𝗅𝗅𝖺𝗌−1/p𝖵𝖾𝗌𝗍𝖺 on each of the p𝖯𝖺𝗅𝗅𝖺𝗌 residues and by 1/p𝖵𝖾𝗌𝗍𝖺 on each of the other p𝖵𝖾𝗌𝗍𝖺−p𝖯𝖺𝗅𝗅𝖺𝗌 scalars, so their statistical distance is

12⁢(p𝖯𝖺𝗅𝗅𝖺𝗌⁢(1p𝖯𝖺𝗅𝗅𝖺𝗌−1p𝖵𝖾𝗌𝗍𝖺)+p𝖵𝖾𝗌𝗍𝖺−p𝖯𝖺𝗅𝗅𝖺𝗌p𝖵𝖾𝗌𝗍𝖺)=p𝖵𝖾𝗌𝗍𝖺−p𝖯𝖺𝗅𝗅𝖺𝗌p𝖵𝖾𝗌𝗍𝖺=δ.

The rest of the game is a randomised function of the view before the i-th answer and of the replaced value, which is independent of that view; each step therefore costs at most δ, and the q steps at most q⁢δ (Math Guide, §“Statistical distance”, Theorem “Properties of statistical distance”, parts (2) and (4)).

In H5 the answers are those of the ideal game, and the key material is that of H3. Neither in H5 nor in the ideal game do the answers depend on the key, so the hops of H3, H2 and H1, taken in reverse order with the answers of the ideal game, lead from H5 to the ideal game at the same costs. Summing the costs of both passes gives the bound. The last statement of the proposition holds because, for K≠𝒪, the map u↦[u]⁢K is a bijection from 𝔽p𝖵𝖾𝗌𝗍𝖺 onto the group of prime order p𝖵𝖾𝗌𝗍𝖺, and translation by 𝖼𝗆i is a bijection of the group; under Assumption 2.8 the point K is uniform. □

Remark 6.11 (Design statement, not proved).

The specification describes the nullifier as combining elliptic-curve cryptography with the Poseidon-based PRF so as to give privacy defence in depth against a weakness in either (protocol specification, §“Faerie Gold attack and fix”). It states that, under the weaker assumption that 𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁 preserves sufficient entropy from 𝗇𝗄 and ρ, the construction would remain unlinkable under a decisional Diffie–Hellman assumption on Pallas even if the Poseidon-based PRF were distinguishable from an ideal PRF (§“𝖯𝗈𝗌𝖾𝗂𝖽𝗈𝗇𝖧𝖺𝗌𝗁 Function”, note; Crypto Guide, §“Diffie–Hellman: computational and decisional”, Definition “Decisional Diffie–Hellman, DDH”; the form assumed in this volume is Assumption 3.16). The volume records this as the specification’s design statement and derives no result from it; Proposition 6.10 relies on Assumption 6.2 instead.

For keys with 𝗎𝗌𝖾⁢_⁢𝗊𝗌𝗄=𝖿𝖺𝗅𝗌𝖾, the key tiers of Proposition 3.18 (“Capability separation”) have the following powers over nullifiers. The full viewing key (𝖺𝗄,𝗇𝗄,𝗋𝗂𝗏𝗄) contains 𝗇𝗄. Its holder computes 𝖣𝖾𝗋𝗂𝗏𝖾𝖭𝗎𝗅𝗅𝗂𝖿𝗂𝖾𝗋𝗇𝗄⁢(ρ,ψ,𝖼𝗆) for every note of the key whose fields it knows, and tests whether that value is in the nullifier set of the note’s pool; that every accepted consumption of the note publishes this value is Lemma 12.5. It does so without spending authority, since the full viewing key yields no 𝖺𝗌𝗄 (Proposition 3.18(a)). A holder of only the incoming viewing key (𝖽𝗄,𝗂𝗏𝗄) cannot link a nullifier to its note, for notes with pairwise distinct ρ, by Proposition 6.10.

Remark 6.12 (Limits).

Proposition 6.10 gives nothing against a holder of 𝗇𝗄, which includes every holder of the full viewing key: such a holder recomputes, and so links, the nullifier of every note of the key whose fields it knows. It does not concern links through other public data, such as timing or the structure of the transaction; the privacy of an Action, with its preconditions, is Theorem 12.12, in “Privacy” (§12.4).