A Deep Dive: Understanding Blockchain Privacy and the Secret Design Stack

Secret Network
Secret Network Ecosystem
7 min readJul 22, 2022

Privacy — what seems like an intuitive concept can become quite hard to pin down once you try to define it. Especially in the crypto space, you’ll get heated discussions on what’s private and what’s not.

The truth is there are many ways to ensure your data isn’t (immediately) accessible by anyone opening a block explorer. You can mix it up, encrypt it, make data private by default, or give people the option to send from private addresses. And that’s just scratching the surface.

Here, we’ll go more into the nuance of blockchain privacy and explain a bit more about the design choices Secret Network made. By being aware of these factors, you can better understand other privacy blockchain solutions — although we always recommend checking out their specific documentation to get more details.

Let’s kick it off:

Privacy for transactions ≠ privacy for smart contracts

One of the most common questions we get asked when people just get to know about Secret Network is, “is it like Monero?” But Monero and Secret Network are different in a crucial way.

Monero and other privacy coins like Zcash give transactional privacy: they make sure your transactional history stays private. Like Bitcoin, they support only transactions. As such, the actions and computations a privacy coin needs to support are limited and mainly include “move value from point A to point B”.

Secret Network is more like Ethereum. It supports all kinds of applications via its privacy-preserving smart contracts, like trading platforms, communication tools, and NFT marketplaces.

This means Secret has to support all the computations a developer could program into a smart contract while keeping data private. In other words: smart contracts on Secret Network have to be Turing complete. That’s why we call privacy on Secret customizable or programmable privacy.

People illustrations by Storyset

This does not mean that one is better than the other, or that Secret offers no transactional privacy at all. But Monero is optimized to specifically give transactional privacy, while Secret is optimized to enable privacy-preserving applications.

Privacy is on a spectrum

Privacy isn’t black and white, where you have either absolute privacy or no privacy at all. It lives on a spectrum, and going for maximum privacy might not be the best choice for you.

Want to be completely untraceable? It might be possible — time will tell — but it’ll come at the cost of flexibility and usability. Absolute privacy makes it hard to share data with trusted others and comply with regulations.

Secret doesn’t pretend to give absolute privacy. Instead, we provide the same level of privacy web2 apps can give you, but with the decentralization benefits of web3. This means that when you make a transaction, the receiver can see your wallet address, but not everything else you own, any loans you requested, or messages you sent.

No, this doesn’t offer the same level of anonymity as Monero, but it fits the use case we’re building for. There are many different users with different needs, after all.

Online illustrations by Storyset

Privacy and anonymity are two different things

We often confuse privacy for anonymity.

However, privacy is the ability to keep your things and actions hidden from the public eye to make sure others can’t see them. Anonymity is the ability to keep your identity private so your actions can’t be traced back to you, even if they can be observed in public.

Let’s look at different crypto privacy solutions to illustrate the difference:

A coin mixer like CoinJoin puts your transaction in a bucket with others to mix it up. Your transaction is sent to the intended recipient, and someone on the blockchain can see the transaction amount and address. But they won’t be able to see who it came from.

On Secret Network, smart contracts encrypt data right from the start; it’s never revealed on the blockchain. It can only be seen by the people who can decrypt this information — the owner and people they share their viewing key with. It’s not observable to the public eye at all. This is what we call privacy.

Security illustrations by Storyset

And this distinction is important to make as it has implications for when your data is truly safe.

With anonymity, it all depends on the anonymity set. For coin mixers, this means: with how many other transactions is yours mixed up? If it’s with a million other transactions, yours will be pretty damn hard to track. But what about 100 other transactions? 10? 5?

With privacy, your safety depends on the mechanisms used to ensure your data is not viewable. For example, how strong are the encryption methods? How easy is it to decipher the code? How much computing power does doing so require?

The more is public, the easier it’s to discover what’s private

This is true for anonymity and privacy solutions: the more public information, the easier it is to guess the private information.

Let’s take a few examples:

If you mix up the source and destination addresses of wallets by using a coin mixer, the data itself is still publicly available — it’s just mixed up. If you know the source and destination of 9 out of 10 transactions included in a set, you also know the 10th one. If you know 8 out of 10, you have a 50% chance of guessing the last one. I.e. the more data is known, the easier it is to figure out the private data, i.e. “fill in the details.”

This also counts for information that’s private as opposed to anonymous. Even on Secret, all traces of public data like interactions with our public coin SCRT or public bridges make it easier to guess the encrypted information.

Question illustrations by Storyset

One way to lower this risk is to make a network private by default — something both Monero and Secret Network do. On Monero, all transactions are done privately without the option to send it to a public wallet address; as is the case on other privacy protocols like Zcash. On Secret, all data in Secret Contracts is encrypted by default unless the developer chooses to make it public in their app design.

This way, Monero and Secret limit the amount of public information from the get-go and lower the risk of others “deciphering” what’s private. Because once the cat’s out of the bag, i.e. data is public — especially on an immutable blockchain — it’s pretty damn hard to get it back in again!

Not all crypto privacy solutions are (entirely) decentralized

Decentralization is one of the core benefits of crypto, so you might expect all crypto privacy solutions to be completely decentralized. But achieving privacy in a decentralized manner is challenging.

That’s why plenty of privacy solutions operate in the web3 space but offer centralized solutions, where data is kept and guarded by one entity. This makes it much easier to guarantee that outsiders can’t access your information. But you have to trust the party you’re handing your data to.

Internet illustrations by Storyset

By introducing centralization, you also get fewer of the benefits that come with decentralized services. Like being protected from services shutting down, single parties seizing control, and hacks because of single points of failure.

However, introducing some points of centralization can help to make privacy crypto solutions more usable until the technology has been developed enough to make it purely decentralized.

Want to learn more?

As you can see, crypto privacy is an area with many nuances to it — there’s a reason there are so many different solutions in the space! We hope this information gave you a better understanding of the what & why of all these different solutions.

While we could keep talking about privacy all day long, that’d make for a very long article. So if you’re not done reading yet, head over to:

--

--

Secret Network Ecosystem
Secret Network Ecosystem

Published in Secret Network Ecosystem

Informational and educational content for developers and users to begin their journey using web3 with confidential data computing.

Secret Network
Secret Network

Written by Secret Network

The Data Privacy Platform For Web3 — build and use blockchain applications that are both permissionless and privacy-preserving.