Zcash in Simplified Technical English

This page is the Simplified Technical English version of section 1 of the Zcash Protocol Specification. The source specification is the normative text. Read the writing rules to understand the marked words.

1. Introduction

Zcash is an implementation of the Decentralized Anonymous Payment scheme Zerocash [BCGGMTV2014]. Zcash has security fixes, and it has improvements to performance and functionality.

Zcash is a bridge between two payment schemes. The first is the existing transparent payment scheme that is used by Bitcoin [Nakamoto2008]. The second is a shielded payment scheme. The shielded payment scheme is secured by zero-knowledge succinct non-interactive arguments of knowledge (zk-SNARKs).

In the source document, technical terms for concepts that are important in Zcash are written in slanted text. This slanted text is a link to an index entry. Italics are used for emphasis and for references between sections of the source document. In cross-references, the symbol § is before section numbers.

When the key words in this list are in ALL CAPS in the source document, interpret them as described in [RFC-2119]:

These words can also be in lower case in the source document, as plain English words. In lower case, these words do not have their normative meanings.

On this page, STE words are in the place of the BCP 14 key words of the source. Refer to the key word table.

The explanation of the most significant changes from the original Zerocash is in Differences from the Zerocash paper.

In the source document and on this page, changes before the Sapling network upgrade are not highlighted. Other changes are highlighted as follows:

All of these changes are also changes from Zerocash.

"Sprout" is the name of the Zcash protocol before Sapling, both before and after Overwinter. In particular, it is the name of the Sprout shielded protocol of that Zcash protocol.

"Sapling" is the name of the Sapling network upgrade. It is also the name of the Sapling shielded protocol. The Sapling shielded protocol is used for the Sapling pool.

"Orchard" is the name of the Orchard shielded protocol. The Orchard shielded protocol is used for the Orchard pool and the Ironwood pool.

This specification has this structure:

1.1. Caution

Zcash security depends on consensus. If a program that interacts with the Zcash network diverges from consensus, the security of that program is weakened or destroyed. The cause of the divergence is not important. These are possible causes:

  • Your program has a bug.
  • This documentation has an error, and you implemented the documentation as written.
  • You do everything correctly, but other software on the network behaves unexpectedly.

The specific cause will not be important to the users of your software who lose their wealth.

But a specification of intended behavior is essential for these tasks:

  • security analysis
  • understanding of the protocol
  • maintenance of Zcash and related software

If you find a mistake in this specification, file an issue at https://github.com/zcash/zips/issues. If the mistake is security-relevant, submit a GitHub Security Advisory to the relevant repository instead. Refer to https://github.com/zcash/zips/security/policy.

1.2. High-level Overview

This overview is intended to be a concise summary of the ideas behind the protocol. The overview is for readers who already know block chain-based cryptocurrencies such as Bitcoin. The overview is not precise in some aspects. It is not part of the normative protocol specification.

This overview applies to these protocols, although their cryptographic constructions are different:

  • Sprout
  • Sapling
  • Orchard

All value in Zcash belongs to some chain value pool. These are the current chain value pools:

  • the transparent pool
  • the Sprout pool
  • the Sapling pool
  • the Orchard pool
  • the Ironwood pool
  • the deferred development fund pool

The Ironwood pool has the same shielded protocol as the Orchard pool.

Transfers of transparent value are essentially the same as in Bitcoin. They have the same privacy properties as in Bitcoin.

Value in a shielded chain value pool is carried by notes [note 1]. An amount and, indirectly, a shielded payment address are specified in each note. A shielded payment address is a destination that a sender can send notes to. As in Bitcoin, the shielded payment address is associated with a private key. This private key can be used to spend notes that are sent to the address. In Zcash, this private key is called a spending key.

Each note has a cryptographically associated note commitment. After a note is created in a transaction and a miner mines that transaction, the note is associated with two more items:

  • a fixed note position in a tree of note commitments
  • a nullifier [note 1] that is unique to that note

To compute the nullifier, the associated private spending key is necessary (or the nullifier deriving key for Sapling-pool, Orchard-pool or Ironwood-pool notes). Without knowledge of at least this key, it is infeasible to correlate the note commitment or note position with the corresponding nullifier.

At a given point on the block chain, an unspent valid note is a note that has these two properties. Its note commitment was publicly revealed on the block chain before that point. Its nullifier was not revealed on the block chain before that point.

A transaction can contain the items in this list. The function of each of these items is the same as in Bitcoin [Bitcoin-Protocol].

  • transparent inputs
  • transparent outputs
  • transparent scripts

A transaction can also include these descriptions:

  • JoinSplit descriptions
  • Spend descriptions
  • Output descriptions
  • Action descriptions (for the Orchard pool and the Ironwood pool)

Together, these are descriptions of shielded transfers. In a shielded transfer, shielded input notes are taken in, or shielded output notes are made, or both.

(For Sprout, each JoinSplit description applies to a maximum of two shielded inputs and a maximum of two shielded outputs. For Sapling, each shielded input or shielded output has its own description. For Orchard, each Action description applies to a maximum of one shielded input and a maximum of one shielded output.)

A transfer of value between chain value pools, either transparent or shielded, is also possible. The amount of such a transfer is always revealed.

In each shielded transfer, the nullifiers of the input notes are revealed. As a result, those notes cannot be spent again. The commitments of the output notes are also revealed. As a result, those notes can be spent in the future.

A transaction also includes computationally sound zk-SNARK proofs and signatures. These proofs and signatures are proof that all of the statements that follow are true, except with insignificant probability.

For each shielded input:

  • [Sapling onward] There is a revealed value commitment to the same value as the input note. [note 2]
  • If the value is nonzero, some revealed note commitment exists for this note.
  • The prover knew the proof authorizing key of the note.
  • The nullifier and note commitment are computed correctly.

For each shielded output:

  • [Sapling onward] There is a revealed value commitment to the same value as the output note. [note 2]
  • The note commitment is computed correctly.
  • It is infeasible to cause the nullifier of the output note to collide with the nullifier of any other note.

For Sprout, the JoinSplit statement also includes an explicit balance check. For Sapling and Orchard, the value commitments that correspond to the inputs and outputs are checked outside the zk-SNARK. The check is that these value commitments balance, together with any net transparent input or output.

In addition, various measures are used to make sure that an unauthorized party cannot change the transaction. These measures are different between Sprout and Sapling or Orchard.

Outside the zk-SNARK, there is a check that the nullifiers for the input notes were not already revealed. That is, the check is that the input notes were not already spent.

A shielded payment address includes a transmission key for a "key-private" asymmetric encryption scheme. Key-private means that only a holder of the corresponding private key can get information from a ciphertext about the key that it was encrypted to. In this context, the name of this private key is the receiving key.

This facility is used to communicate encrypted output notes on the block chain to their intended recipient. The recipient can use the receiving key to scan the block chain for notes addressed to that recipient. Then the recipient can decrypt those notes.

In Sapling and Orchard, there is a full viewing key for each spending key. With the full viewing key, a holder can recognize both incoming and outgoing notes without spending authority. This is implemented by an additional ciphertext in each Output description or Action description.

The privacy properties of Zcash have this basis. When a spender spends a note, the spender proves only that some revealed commitment for that note exists. The spender does not reveal the identity of that commitment. Thus it is not possible to link a spent note to the transaction that the note was created in.

That is, from the point of view of an adversary, there is a set of possibilities for a given note input to a transaction. This set is the note traceability set of that note input. The set includes all previous notes that the adversary does not control and does not know to be spent. [note 3]

This is different from other proposals for private payment systems that are based on the mixing of a limited number of transactions. Examples of such proposals are CoinJoin [Bitcoin-CoinJoin] and CryptoNote [vanSaberh2014]. Thus those proposals have smaller note traceability sets.

The nullifiers are necessary to prevent double-spending. Each note on the block chain has only one valid nullifier. Thus, in an attempt to spend a note two times, the nullifier is revealed two times. As a result, the second transaction is rejected.

Footnotes

  1. In Zerocash [BCGGMTV2014], notes were called "coins", and nullifiers were called "serial numbers".
  2. For the Orchard shielded protocol, each Action has one revealed value commitment, to the net value spent by the Action. An Action does not have one value commitment for the input note and one for the output note.
  3. We make this claim only for fully shielded transactions. We do not exclude the possibility that an adversary makes probabilistic inferences about transaction linkage. For such inferences, the adversary can use data in the cleartext of a transaction, such as the number of inputs and outputs. The adversary can also use metadata-based heuristics, such as timing. For the consequences of this for partially shielded transactions, refer to [Peterson2017], [Quesnelle2017], and [KYMM2018].

References

[BCGGMTV2014]
Eli Ben-Sasson, Alessandro Chiesa, Christina Garman, Matthew Green, Ian Miers, Eran Tromer, and Madars Virza. Zerocash: Decentralized Anonymous Payments from Bitcoin (extended version)
[Bitcoin-CoinJoin]
CoinJoin - Bitcoin Wiki
[Bitcoin-Protocol]
Protocol documentation - Bitcoin Wiki
[KYMM2018]
George Kappos, Haaroon Yousaf, Mary Maller, and Sarah Meiklejohn. An Empirical Analysis of Anonymity in Zcash
[Nakamoto2008]
Satoshi Nakamoto. Bitcoin: A Peer-to-Peer Electronic Cash System
[Peterson2017]
Paige Peterson. Transaction Linkability
[Quesnelle2017]
Jeffrey Quesnelle. On the linkability of Zcash transactions
[RFC-2119]
Scott Bradner. Request for Comments 7693: Key words for use in RFCs to Indicate Requirement Levels
[vanSaberh2014]
Nicolas van Saberhagen. CryptoNote v 2.0