Implementing some form of “Zero-Knowledge” proofs, based on the zk-SNARKs model pioneered by Zcash, into the Tezos protocol has been on the radar of creator Arthur Breitman since the original Tezos white paper. With the Tezos Mainnet humming along and the first protocol amendment vote on the horizon, it seems that some meaningful progress has been made which could pave the way for zk-SNARKs integration with Tezos.

Just days ago, on Nov. 29, a commit was made to the Tezos public Gitlab explaining a new OCaml binding which is intended to allow easy interfacing with Zcash’s zk-SNARKs library to bring shielded transactions to the Tezos network.

The goal of shielding a transaction is to provide verifiable proof that the transaction took place without divulging any information about the transaction, such as the associated accounts, balances, or amount of the transaction.

This type of privacy is a key feature of the Zcash project which can allow for “transparent” transactions, where all transaction information is disclosed, similar to Bitcoin, for example, or “zero-knowledge” transactions where all related information about a transaction is kept private except for verifiable proof that the transaction took place.

zk-SNARKs Explained

The term zk-SNARK stands for “Zero-Knowledge Succinct Non-Interactive Argument of Knowledge.” Sound confusing? It’s not too mindboggling once we break it down a little further with concrete examples.

According to Zcash, a major pioneer of research into using zero-knowledge proofs coupled with blockchain, zk-SNARKs allows “one party (the prover) to prove to another (the verifier) that a statement is true, without revealing any information beyond the validity of the statement itself.”

In relation to blockchain and cryptocurrency, this means allowing a shielded transaction to be verified without revealing the underlying information about the transaction. This is achieved when the sender of the transaction generates a proof (a zk-SNARK) which constructs a mathematical formula to prove that the transaction amount changed hands, the sender was legitimately able to sign the transaction, and that the transaction cannot be modified by an outside party who was not part of the original transaction.

In short, when the sender originates a shielded transaction, a zk-SNARK is created by the sender which lives on the blockchain and can be referenced in the future to mathematically verify, without revealing information, that the transaction took place.

This kind of privacy, achieved on a public blockchain, would help advance the use-cases for cryptocurrency by opening up more institutional use thanks to increased security.

Improving zk-SNARKs Efficiency

Originally, the zk-SNARKs algorithms developed by Zcash was powerful, yet resource intensive. Prior iterations of the function could take several minutes to generate a zk-SNARK and use several Gigabytes of memory during the process.

However, thanks to continuing research by Zcash, the algorithm to generate a zk-SNARK has been entirely re-written and now provides for generating a zero-knowledge proof in a matter of seconds using just 144 bytes of memory.

Until the limitation of speed and system resource hogging could be overcome, zk-SNARKs would remain a promising yet still unusable privacy feature for mass cryptocurrency adoption.

Why This Matters For Tezos

According to a document, authored by Sophia Gold, which accompanied the Gitlab commit, a new native OCaml library has been created to allow for the addition of the latest iteration of Zcash’s highly efficient zk-SNARKs algorithm, known as Sapling, into the Tezos protocol.

This move would allow Tezos to eventually begin offering shielded transactions which can generate proofs in seconds. Furthermore, it would be built on Zcash’s proven technology which has spent years in the development pipeline.

This move would position Tezos as one of a small handful of blockchains offering both smart contracts and shielded transactions. Zcash does not currently implement native smart contracts.

The document also mentions implications for smartphone use, saying, “This allows even mobile devices to generate zero knowledge proofs and will hopefully bolster the prevalence of shielded transactions, resulting in greater collective privacy.”

Tezos would be among the first major decentralized blockchains to graft this technology into the native protocol.

When Will zk-SNARKs Be Implemented In Tezos?

When asked by Crypto Insider for a timeframe on zk-SNARKs integration, Breitman explained that this decision does not rely on a single person or group of developers.

“The beauty of on-chain governance is that ‘if’ and ‘when’ is all up to the Tezos community who manages this type of decision,” Breitman said.

He added, “My advice is to be conservative and test integration thoroughly before considering it for a vote.”

The real question, perhaps, is when zk-SNARKs integration might be ready for a protocol upgrade vote, and we don’t yet have an answer on that front.

Tezos Has Deep Zcash Connections

This isn’t the first time Tezos and Zcash have crossed paths. Back in 2017, prior to the Tezos fundraiser, Zooko Wilcox, creator of Zcash, disclosed he was personally advising the Tezos project.

In a blog post dated June 29, 2017, Wilcox explained why he found interest in Tezos:

“The core idea of Tezos — formalized and automated governance of a decentralized protocol—is a deeply powerful idea, and I want to see it implemented and deployed, in the hopes that it can greatly help humanity.”

Wilcox also expressed his agreement back in October of last year with the way Breitman described why Tezos should adopt methods similar to Zcash versus Ethereum when it comes to scaling:

Excellent essay by Arthur Breitman: “Scaling Tezos”—https://t.co/kVoFvapxvT My sympathies lie this way more than the sharding way. — zooko (@zooko) October 16, 2017

In addition to Breitman’s comments today concerning how zk-SNARKs could be implemented on Tezos, he also complimented Zcash for their ongoing efforts. “The work of the Zcash team is impressive,” Breitman said, “and it stands atop equally impressive research.”

zk-SNARKs implementation would be a massive step for Tezos, putting it ahead of many competitors.