-
Notifications
You must be signed in to change notification settings - Fork 84
Two-step admin handover with pending_admin slot #231
Copy link
Copy link
Closed
Labels
GrantFox OSSIssue tracked in GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardIssue may be eligible for a GrantFox rewardOfficial Campaign | FWC26Campaign: Official Campaign | FWC26Campaign: Official Campaign | FWC26area:onchainOn-chain (Soroban) areaOn-chain (Soroban) areakind:securitySecurity hardeningSecurity hardening
Description
Activity
Metadata
Metadata
Assignees
Labels
GrantFox OSSIssue tracked in GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardIssue may be eligible for a GrantFox rewardOfficial Campaign | FWC26Campaign: Official Campaign | FWC26Campaign: Official Campaign | FWC26area:onchainOn-chain (Soroban) areaOn-chain (Soroban) areakind:securitySecurity hardeningSecurity hardening
Problem Statement. Admin is set once at
init()and never changed. There is no two-steprotation, no revocation path for a lost admin key, and no recovery code.
Why it matters. Lost admin keys are an obvious, severe incident. A maintainer must
have a way to rotate the admin without redeploying the Wasm.
Technical Context.
KEY_ADMINis a single value. There is nopending_adminslot.Expected Outcome.
rotate_admin(new_admin)is callable only by current admin, setsKEY_PENDING_ADMIN.accept_admin()is callable only bypending_admin, replacesKEY_ADMIN, clearsKEY_PENDING_ADMIN, emitsAdminRotatedEvent.accept_admindeadline enforced (configurable).Acceptance Criteria.
pauseafter accepting-rotation is complete.accept_admin.Files or modules likely to be affected.
src/lib.rs,tests/aid_escrow_tests.rs.Difficulty. Hard
Estimated effort. M
Backlog item #23 from `docs/maintainer-issue-backlog.md.