How do you design admin control for a protocol so it can be maintained without making users trust a single person?
What the interviewer wants to hear
- Minimise privileged functions and document them
- Split powers into roles with least privilege
- Use multisigs with hardware keys for admin roles
- Timelocks on upgrades and parameter changes, with events for monitoring
- Fast emergency pause, and plan for gradual decentralisation
Model answer
I start by keeping privileged functions to a minimum and listing exactly what each one can do, including worst cases. Then I split powers into roles with least privilege: a pauser, a parameter manager, an upgrader, and no single key that can do everything. Each role is held by a multisig like Safe, with signers on hardware wallets, and important roles need several approvals. Upgrades and risky parameter changes go through a timelock, often 48 hours or more, and emit events, so users and monitors can react or exit. An emergency pause can act quickly, but it should only stop actions, not move funds. Bounds checks on parameters limit damage even from valid admins. Over time, control can move to on-chain governance with voting delays and quorum, and some parts can be made immutable.
Can you answer it under time pressure?
Take a timed medium round and get scored on every answer.
More medium Blockchain Developer questions
- What is a reentrancy attack and how do you prevent it?
- What techniques do you use to reduce gas costs in Solidity contracts?
- How do you test a smart contract before deploying it to mainnet?
- How do upgradeable smart contracts work, and what are the trade-offs?
- What is a blockchain oracle and how do you use price data safely?
- How do signature-based approvals like ERC-2612 permit and Permit2 work, and what are their risks?
- How do you build a reliable dApp frontend that reads and writes contracts with viem and wagmi?
- How do chain reorganizations affect a dApp or backend service, and how do you handle them?
- Walk me through how you deploy a set of contracts to mainnet safely.