The primary trust assumption is the oracle operator. The oracle has the authority to mint wNNS by attesting that a corresponding NNS deposit was received. A compromised oracle could mint unbacked tokens.
- Per-tx mint cap — Limits max single mint to 100,000 wNNS
- Daily mint cap — Rolling 24h window caps total minting at 1,000,000 wNNS
- Duplicate prevention — Each NNS tx hash can only trigger one mint
- Pausable — Owner can halt all operations instantly
- Oracle rotation — Compromised oracle can be swapped without redeploy
- UUPS upgradeable — Critical bugs can be patched via proxy upgrade
- Ownable2Step — Ownership transfer requires explicit acceptance
- ReentrancyGuard — Protection against reentrancy on all state-changing functions
- No ETH held — Vault only manages wNNS supply, no honeypot of value
- Oracle runs on isolated infrastructure with minimal permissions
- Oracle hot wallet holds only enough ETH for gas
- NNS treasury wallet is a cold wallet with multi-sig (recommended)
- All oracle actions are logged and monitored
- Deploy new implementation contract
- Owner calls
upgradeToAndCall()on the proxy - Storage layout must be compatible (append-only state variables)
- Recommended: Use a Timelock controller for production upgrades
- Reentrancy on mint/burn paths
- Storage layout compatibility across upgrades
- Oracle front-running resistance
- Integer overflow in fee calculations
- Proxy initialization protection
- Access control on all admin functions
- Event emission for all state changes
- Edge cases: zero amount, zero address, max uint256