Embracing Unpredictability: The Role of Randomness in Blockchain

Randomness is a synonym for unpredictability and something Web3 developers wish for. But why is it a good thing in the context of blockchain, and how does it affect computations? In this article, we are exploring the benefits of randomness and why it this something so important to achieve when it comes to on-chain and off-chain operations.

Randomness can be found everywhere within the most ancient of things: nature. Be it the formation of clouds, raindrops, and even earthquakes, there is a great dose of unpredictability all around us.

On the other hand, almost everything mankind creates has a predictability component — especially when it comes to machines. They’re built with formulas and algorithms and designed for a specific use, following the same processes for a specific use.

Predictability also applies to computers and computations, so it’s easy to understand why randomness can be hard to achieve in deterministic systems. However, the unpredictability factor is needed sometimes, namely when it comes to blockchain.

Randomness in Blockchain

Randomness in the context of blockchain technology plays a crucial role in various processes within the blockchain. One common use of randomness is in the selection of validators or leaders in a consensus algorithm.

Nodes often need to agree on the order of transactions and reach a consensus to validate blocks. To prevent malicious actors from predicting or controlling this process, randomness is introduced. This ensures a fair and decentralized selection of validators, making it more difficult for any single entity to manipulate the system.

Randomness in blockchain isn’t easy to achieve, but it’s often done so through cryptographic techniques or a combination of various inputs, ensuring that the outcome is unpredictable and tamper-resistant. This adds an extra layer of security and fairness to the decentralized nature of blockchain networks.

Can True Randomness be Achieved?

This is one of the main challenges blockchain developers face, due to the deterministic nature of computer systems. Computers operate based on algorithms and deterministic processes, making it inherently difficult to generate truly random values.

Randomness in Web3 Oracles

Oracles are systems or services providing external data to a blockchain. Randomness isn’t an inherent characteristic of blockchain or even computational structures, but there are added issues when it comes to oracles specifically.

Centralization: Many oracles rely on centralized sources for randomness, such as random number generators (RNGs) operated by a single entity. This introduces a single point of failure and potential manipulation, as the centralized source could be compromised or controlled.

Trust: Even if the oracle claims to use a decentralized source of randomness, trust in the integrity of the data provided is essential. Verifying the randomness provided by a decentralized source can be difficult, especially if the source is not transparent or if there are incentives for dishonest behavior.

Deterministic Systems: Like blockchains, computer systems are deterministic by nature, making it challenging to generate truly random values. Oracles may struggle to provide randomness that is not predictable or manipulable, especially if they rely on deterministic algorithms or processes.

External Influences: External factors, such as network latency, system failures, or malicious attacks, can affect the randomness provided by an oracle. Ensuring resilience against these influences while maintaining the integrity of the randomness is a significant challenge.

Security: Randomness in oracles is often used in critical applications like cryptographic protocols, lotteries, or gaming. Ensuring the security and unpredictability of the randomness is essential to prevent exploits or attacks that could compromise the integrity of these applications.

A Verifiable Lottery

After releasing our oracle framework for TEE-based oracles without repudiation, our team is preparing a randomness oracle to showcase at Sub0 Asia 2024. The Polkadot developers’ event will take place this March in Bangkok, Thailand, where we will be introducing the results of our experiment.

We combined randomness and TEEs to bring forth a hypothetical lottery system where every participant can get proof they were included in the ballot — this proves that privacy and accountability can go hand in hand without compromising each other.

• • •

About Integritee

Integritee is the most scalable, privacy-enabling network with a Parachain on Kusama and Polkadot. Our SDK solution combines the security and trust of Polkadot, the scalability of second-layer Sidechains, and the confidentiality of Trusted Execution Environments (TEE), special-purpose hardware based on Intel Software Guard Extensions (SGX) technology inside which computations run securely, confidentially, and verifiably.

Community & Social Media:
Join Integritee on Discord | Telegram | Twitter Medium | Youtube LinkedIn | Website

L2 Sidechains | Trusted Off-chain Workers | Teeracle | Attesteer | Securitee | Incognitee

Integritee Network:
Governance | Explorer | Mainnet | Github