How Stylus enables privacy innovation on Fairblock

What is Fairblock?
Fairblock is a confidentiality protocol that enables confidential and decentralized transaction execution. It leverages advanced cryptographic techniques to protect sensitive information throughout the lifecycle of a transaction. Fairblock leverages dynamic, confidential computing to mitigate centralized risks and prevent information leakage in decentralized applications. This unlocks Credible and Capital-Efficient DeFi mechanisms and AI models.
What is Stylus?
Stylus allows developers to write smart contracts in languages that compile to WASM—such as Rust, C, and C++—while remaining fully interoperable with the EVM. Introduced to Arbitrum's mainnet on September 3rd, the Stylus Rust SDK and CLI allow developers to start building today.
Case Study
The opportunity
Fairblock, a confidentiality protocol, faced inefficiency challenges in achieving efficient onchain cryptographic operations within the Ethereum Virtual Machine (EVM) environments.
The protocol primarily focuses on confidentiality through Multi-Party Computation (MPC) to secure onchain data and transactions so no privileged party can exploit the leaked information in public mempools without permission, leading to credible onchain DeFi and AI economies. However, Fairblock and other confidentiality projects faced an obstacle: they could not write smart contracts leveraging the necessary cryptography libraries with the legacy EVM as they were written in Rust or Go.
Additionally, onchain decryption on the EVM was prohibitively inefficient, as performing these operations within a single block would exceed the gas limit, making blockchain applications leveraging encryption impractical.
These limitations constrained Fairblock’s ability to provide scalable and efficient solutions on Ethereum-compatible chains.
The Solution
The solution is either a. installing EVM precompiles for EVM L1s/L2s, b. running VMs that support Rust or Go through Stylus or Cosmos SDK modules, or c. coprocessing confidential computing in Fairblock.
Stylus marked a significant turning point for Fairblock. According to Peyman Momeni, the co-founder of Fairblock, Stylus’s custom execution environment, where every programming language gets compiled down to WASM, made execution much more efficient and permissionless.
With Stylus, Fairblock engineers could write functions in Rust and bring them onchain in a reliable, efficient and permissionless way without learning a new programming language. This eliminated the need for complex workarounds and expanded the protocol’s ability to reach meaningful applications with confidentiality solutions.
Additionally, Stylus reduced the computational overhead associated with onchain cryptographic operations. This means that Fairblock achieved a more feasible approach for onchain decryption within the constraints of a block, enabling more affordable real-time confidentiality features.
Beyond Stylus's technical capabilities, Momeni said Stylus was a stepping stone that allowed Fairblock to integrate its confidentiality protocol into the Ethereum-based ecosystem, unlocking new opportunities for adoption.
Fairblock’s Stylus-based approach has been widely adopted within the Arbitrum ecosystem, primarily due to its permissionless framework and streamlined developer onboarding. Developers do not need to learn new languages or install extra pre-compiles to get started quickly and easily.
Implementation and Results
Fairblock launched its first public testnet, FairyRing, in March of last year, allowing app developers to test integrations for programmable privacy in their applications. Thanks to Stylus, a range of innovative applications that were previously inefficient due to technical or economic limitations can now launch within the Ethereum ecosystem, leveraging Fairblock. These new possibilities span several categories, including:
- Credible Auctions: Fairblock can enable fast decentralized and sealed-bid auctions that are not prone to bid censorship, shilling, frontrunning, and other manipulation techniques by privileged market players. This can create more credible economies for Intent matching, RWA and NFT auctions, liquidations, and Fair token launches.
- AI Agents and Private Data Market Places: AI models can rely on privately accessible data, making it crucial to protect privacy while encouraging individuals and institutions to contribute their data securely. Additionally, AI agents can monetize their verifiable models by maintaining confidentiality and trust. MPC also mitigates the risk of these agents being unruggable and unstoppable, as it secures private keys and execution processes against the risks of centralization.
- Onchain Gaming: Developers can introduce dynamic confidentiality in games, enabling features like encrypted game logic, mystery boxes, and randomized reward systems. These elements enhance gameplay by introducing surprises and protecting critical mechanics from being reverse-engineered.
- Decentralizing the MEV Supply Chain: Fairblock enables encryption that helps prevent toxic Maximal Extractable Value (MEV) exploits without relying on centralized relayers, reducing front-running and sandwiching in DeFi. This decentralizes solutions for MEV protection and creates a fairer ecosystem for traders. Toxic MEV can happen in swaps, intent architectures relying on good behavior of offchain actors for execution quality, forced liquidations in perp protocols, European options, and various other scenarios.
- Enhanced Governance Models: Onchain governance systems can integrate confidential voting mechanisms, protecting them against manipulation during the voting window period and heightening privacy while maintaining verifiability. This promotes transparent yet secure decision-making processes.
- Confidential Payments: Payments and transaction data can be encrypted onchain, protecting users from surveillance or exploitation. This is especially valuable for sensitive financial interactions. Fairblock can address regulatory concerns by providing post-execution auditability through decentralized threshold encryption.
- Decentralized PvP Markets: Applications like prediction markets can now leverage pre-execution encryption to protect sensitive data and credible neutrality. This promotes fairness, prevents manipulation, and enhances user trust in these markets.
Stylus empowers Fairblock to offer groundbreaking confidentiality solutions in DeFi, AI and gaming. Stylus significantly reduced onchain computational costs and enabled developers to work with Rust-based cryptographic libraries, ultimately broadening the scope of what is achievable on blockchain networks.