Over the past couple of years zero-knowledge technology has become one of the hottest subjects in crypto. But what is zero-knowledge? Why do we need it? Why is it good to know nothing?
This short post will explain zero-knowledge in a way that’s easy to understand.
What is zero-knowledge, or a zero-knowledge proof, aka zkProof?
First up… writing zero-knowledge before everything is clunky which is why it is usually abbreviated to zk. Not only is it shorter but putting zk before a word makes it look more sci-fi.
So what is zero-knowledge?, or to use the full title “What is a zero-knowledge proof” aka zkProof.
In its simplest terms, a zkProof is a way for one party to prove to another party that they know something without revealing what that something is. For example proving that you know a password without revealing the password itself.
How do zkProofs work?
The most common example of how a zkProof works is based on the story of Ali Baba’s cave.
There is a cave, this cave has a single entrance but just a few metres in it splits in two.
The cave is circular, however there is a door halfway along the passage that can only be unlocked with a secret password.
Bob and Alice
Bob and Alice visit the cave and Bob shows Alice the locked door.
Bob knows the password but doesn’t want to tell Alice as he has really bad password management and uses the same password on all his accounts. Bob is stupid. Don’t be like Bob.
How can he prove to Alice that he knows the secret password without telling her what it is?
- First they assign each fork a letter, A & B.
2. Next, Alice waits outside while Bob goes in and chooses his path (A or B). In this case Bob chooses A.
3. After a short while Alice enters the cave and shouts what path she wants Bob to appear from.
In this case she calls out B which means that Bob must use the password to go through the door.
4. Bob successfully uses the password and appears at B.
5. Of course there was a 50% chance that Bob had chosen Route B and didn’t know the password. He was just lucky.
Alice knows this so they repeat the experiment, reducing the chance that Bob is just lucky. After around 20 times the odds that Bob was lucky is about one in a million.
If Bob fails even once Alice knows he is a fraud and he doesn’t know the password.
What is zero-knowledge used for?
In crypto, zk tech is used for three main reasons. Transactions, privacy, and proof of identity.
Transactions, aka zkRollups:
zkRollups are technology that makes cryptocurrency transactions faster and cheaper. They do this by combining, or rolling up, a big bunch of transactions (off-chain) into one big transaction and submitting proof of these transactions to the blockchain.
Zk technology can also be used to keep transactions private. Much like using a VPN.
Aztec are one of the leaders in what are known as zk zk rollups, or private zkRollups- giving you the ability to send crypto like it’s cash. No one needs to know what you are spending your money on. There is no public paper trail.
Proof of identity, aka Know Your Customer (KYC):
Say I need to prove to someone that I am who I say I am but I don’t trust you enough to give you a copy of my passport. With a zkProof I can simply show you that my identity has already been verified in a way that cannot be copied, edited, or used by another party and that I am in fact, who I say I am.
No third party needs to see, and potentially lose or steal, your personal documents.
That’s it, a very brief rundown of zero-knowledge without the fluff and the jargon. Hope you have a better understanding of what that zk means and remember, don’t be like Bob and reuse passwords.