RPC Provider Guide¶
Crucible reproduces historical blockchain exploits by forking the chain at a specific block using Foundry's anvil. To accomplish this, anvil necessitates an archive node (or "full archive node") capable of serving historical state data.
1. Archive vs Full Node¶
Full nodes aggressively prune state data. Archive nodes retain the entire state trie since genesis.
| Feature | Full Node | Archive Node |
|---|---|---|
| Latest block state | Supported | Supported |
Historical state (eth_getBalance at old block) |
Fails (pruned after ~128 blocks) | Supported (stores all state since genesis) |
eth_getBlockByNumber (old blocks) |
Supported (block headers kept) | Supported |
eth_getCode / eth_call (old blocks) |
Fails | Supported |
| Disk space (Ethereum) | ~1 TB | ~12+ TB |
| Disk space (BSC) | ~1 TB | ~10+ TB |
Crucial Requirement: For multi-chain exploits involving BSC or Polygon at 2021-era blocks, paid archive providers are almost always required as free providers aggressively prune non-Ethereum chains.
2. Provider Comparison¶
Ethereum (Free Archive Available)¶
| Provider | Archive Depth | Rate Limit | Cost | Practicality for Testbed |
|---|---|---|---|---|
| Ankr (rpc.ankr.com/eth) | Full archive (with API key) | 300M CU/month | Free tier | Best free option — sign up at app.ankr.com |
| LlamaNodes (eth.llamarpc.com) | Full archive | 25 req/s | Free | Usable, but frequently rate-limits Anvil |
| PublicNode | Limited (~128 blocks) | 10 req/s | Free | Fails for deep historical blocks |
| Alchemy | Full archive | Varies | Free tier + paid | Excellent |
| QuickNode | Full archive | Varies | Paid | Excellent |
BSC & Polygon (Paid Archive Recommended)¶
Free tiers for BSC and Polygon routinely fail to serve complete state queries (e.g., anvil_setBalance) at older blocks.
| Provider | Archive Depth | Cost | Practicality for Testbed |
|---|---|---|---|
| GetBlock (go.getblock.io) | Full archive | ~$39/mo | Highly Recommended (Tested) |
| QuickNode | Full archive | Varies | Excellent (Per-chain pricing) |
| Chainstack | Full archive | Varies | Excellent |
| Ankr | Full archive | Varies | Good (Requires Premium tier for L2s) |
| LlamaNodes / PublicNode | Pruned | Free | Fails for historical exploit reproduction |
3. Recommended Provider: GetBlock¶
Based on extensive operational testing, GetBlock (Starter Plan) is the most practical option for multi-chain research:
- Coverage: Full Archive for BSC, Polygon, and Ethereum.
- Rate Limit: 20 RPS (sufficient for Anvil's throttled fetching).
- Cost: ~$39/mo (supports 2 endpoints simultaneously, covering BSC + Polygon).
4. Configuration in Crucible¶
Step 1: Set Environment Variables¶
Configure your provider credentials in the .env file at the root of the testbed:
# Ethereum archive — ANKR free tier (sign up at https://app.ankr.com)
ETH_RPC_URL=https://rpc.ankr.com/eth/YOUR_ANKR_API_KEY
# BSC Archive (GetBlock or your premium provider)
BSC_RPC_URL=https://go.getblock.io/YOUR_ACCESS_TOKEN
# Polygon Archive (GetBlock or your premium provider)
POLYGON_RPC_URL=https://go.getblock.io/YOUR_ACCESS_TOKEN
Step 2: Configure Rate Limiting¶
Crucible employs a robust TokenBucket algorithm to ensure Anvil's heavy parallel fetching does not exceed your provider's rate limits (mitigating HTTP 429 Too Many Requests errors).
Configure these limits per-provider within testbed.yaml:
rpc_providers:
ethereum:
- name: ankr_free
url: "${ETH_RPC_URL}"
rate_limit: 30 # 30 requests per second
burst_limit: 50 # Allow temporary bursts up to 50
Fallback Providers: You may define multiple providers per chain. If a provider reaches its rate limit or encounters an outage, the testbed will automatically failover to the next configured endpoint.