The technical content top engineers rely on to level up.
18 min read
Elliptic Curves over Finite Fields What do elliptic curves in finite fields look like? It’s easy to visualize smooth elliptic curves, but what do elliptic curves over a finite field look like? The...
16 min read
Invariant Testing in Foundry Introduction In this article, we will discuss invariants and how to perform an invariant test on Solidity smart contracts using Foundry test suites. Invariant testing is...
6 min read
Solidity Mutation Testing Mutation testing is a method to check the quality of the test suite by intentionally introducing bugs into the code and ensuring the tests catch the bug. The kind of bugs...
6 min read
Ethereum precompiled contracts Ethereum precompiles behave like smart contracts built into the Ethereum protocol. The nine precompiles live in addresses 0x01 to 0x09. The utility of precompiles falls...
11 min read
How ERC721 Enumerable Works An Enumerable ERC721 is an ERC721 with added functionality that enables a smart contract to list all the NFTs an address owns. This article describes how functions and how...
7 min read
The interest rate model of Aave V3 and Compound V2 Interest rates in TradFi (traditional finance) are largely determined by central banks and influenced by market factors. In contrast, DeFi interest...
3 min read
The Fallback Extension Pattern The fallback-extension pattern is a simple way to circumvent the 24 KB smart contract size limit. Suppose we have functions and in our primary contract and wish to add...
6 min read
EIP 1967 Storage Slots for Proxies EIP 1967 is a standard for where to store information that proxy contracts need to execute. Both the UUPS (Universal Upgradeable Proxy Standard) and the Transparent...
12 min read
The staking algorithm of SushiSwap MasterChef and Synthetix The MasterChef and Synthetix staking algorithms distribute a fixed reward pool among stakers according to their time-weighted contributions...
5 min read
The second preimage attack for Merkle Trees in Solidity The _second preimage attack_ in Merkle trees can happen when an intermediate node in a Merkle tree is presented as a leaf. The name of this...
4 min read
How Chainlink Price Feeds Work Chainlink price oracles are smart contracts with public view functions that return the price of a particular asset denominated in USD. Off-chain nodes collect the...
8 min read
Layer 2 Calldata Gas Optimization Update for mid 2024: As of the Dencun upgrade, calldata optimization doesn't have as much of an impact since the transactions on most L2s are stored on blobs,...