Notes on deploying the Anoma Protocol Adapter (pa-evm) to BNB Smart Chain. This is a living doc — updated as we go.
The pa-evm project targets evm_version = "osaka" in its Solidity compiler settings (Solidity 0.8.33). Osaka (also referred to as Fusaka in some contexts) is the upcoming Ethereum upgrade — not yet live on Ethereum mainnet, let alone other chains.
BNB Smart Chain supports Cancun opcodes since the Tycho hard fork (mid-2024). The latest BNB hard fork is Fermi (Jan 2026), which brought Pectra-level features and EVM Super Instructions, but not osaka/Fusaka.
Does this matter for us? Not really. We checked what EVM features the codebase actually uses:
ProtocolAdapter.solusesReentrancyGuardTransient(OpenZeppelin 5.5.0), which relies onTSTORE/TLOAD— these are Cancun opcodes (EIP-1153), not osaka.- RISC Zero contracts (
Groth16Verifier,Router,EmergencyStop) only need basic EVM + BN256 precompiles. Nothing fancy. - No osaka-specific opcodes (like EOF) are used anywhere in the codebase.
So we just override with FOUNDRY_EVM_VERSION=cancun at deploy time. This is the same thing RISC Zero does when deploying to chains like Avalanche and Linea that don't support the latest EVM version.
RISC Zero has not deployed their verifier contracts on BNB Smart Chain. They support ~17 chains — BNB isn't one of them. We verified this by:
- Checking the RISC Zero docs — no BNB listed
- Checking their deployment.toml on GitHub — no BNB entry
So we're deploying the RISC Zero verifier stack ourselves, same as we did for Aurora. The pa-evm project already has the RISC Zero v3.0.1 contracts as Soldeer dependencies, and there's a test deployment script (contracts/test/script/DeployRiscZeroContracts.s.sol) that deploys the full stack.
Three contracts, in order:
RiscZeroGroth16Verifier— the actual ZK proof verifier. Constructed withControlID.CONTROL_ROOTandControlID.BN254_CONTROL_ID(hardcoded constants for RISC Zero v3.0.1).RiscZeroVerifierEmergencyStop— wraps the verifier with a pause mechanism. A guardian address can emergency-stop all verification.RiscZeroVerifierRouter— the entry point. The ProtocolAdapter talks to this. It routes proof verification to the right verifier based on a 4-byte selector (0x73c457bafor v3.0.1).
The router address is what we'll later pass to the ProtocolAdapter deployment.
| BNB Testnet | BNB Mainnet | |
|---|---|---|
| Chain ID | 97 | 56 |
| RPC (Alchemy) | https://bnb-testnet.g.alchemy.com/v2/<KEY> |
https://bnb-mainnet.g.alchemy.com/v2/<KEY> |
| Explorer | https://testnet.bscscan.com | https://bscscan.com |
| Faucet | https://www.bnbchain.org/en/testnet-faucet | N/A |
Alchemy API key required. BNB supports EIP-1559, so no --legacy flag needed (unlike Aurora).
The official BNB testnet faucet at https://www.bnbchain.org/en/testnet-faucet requires holding 0.002 BNB on mainnet. Alternatives:
- https://faucet.quicknode.com/bnb-smart-chain/bnb-testnet
- https://faucet.chainstack.com/bnb-testnet-faucet
Reusing the aurora-dev wallet created for Aurora deployments:
Deployer address: 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b
Security note: This is a testnet-only dev wallet. For mainnet, use a hardware wallet or multisig.
PR: #479
Dry-run:
just risczero-simulate 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b bnb-testnetActual deployment:
just risczero-deploy aurora-dev 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b bnb-testnet --sender 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b "--password="| Contract | Address |
|---|---|
| RiscZeroGroth16Verifier | 0xa052548fdbea6a8574f2a0dB582EA3286A6d9949 |
| RiscZeroVerifierEmergencyStop | 0xBbcD45801a3c3B858fbc66674FE7c9f94e33dC72 |
| RiscZeroVerifierRouter | 0x7C1B7b8fEB636eA9Ecd32152Bce2744a0EEf39C7 |
5 transactions total (3 creates + addVerifier + transferOwnership), all in block 92240773.
Total cost: 0.0002616799 BNB
Deployer/admin/guardian: 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b
Note: Same addresses as Aurora testnet deployment — deterministic from same deployer nonce.
FOUNDRY_EVM_VERSION=cancun IS_TEST_DEPLOYMENT=true EMERGENCY_STOP_CALLER=0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b \
just contracts-deploy aurora-dev bnb-testnet --sender 0xcD5679555424B5132E1bAbE1FD965c44BF1dDb7b "--password="| Contract | Address |
|---|---|
| ProtocolAdapter | 0x33d4F0c88ef555E105Ba5e5F1aFbF34d6f650964 |
Block: 92241607. Cost: 0.0009885864 BNB
just risczero-verify \
0xa052548fdbea6a8574f2a0dB582EA3286A6d9949 \
0xBbcD45801a3c3B858fbc66674FE7c9f94e33dC72 \
0x7C1B7b8fEB636eA9Ecd32152Bce2744a0EEf39C7 \
97FOUNDRY_EVM_VERSION=cancun just contracts-verify-sourcify 0x33d4F0c88ef555E105Ba5e5F1aFbF34d6f650964 97
FOUNDRY_EVM_VERSION=cancun just contracts-verify-etherscan 0x33d4F0c88ef555E105Ba5e5F1aFbF34d6f650964 97