Skip to content

fix: remove cfg(production) admin bypass + merge pass pool reserves o…#425

Open
0xksure wants to merge 2 commits intometaDAOproject:developfrom
0xksure:fix/high-severity-security-fixes
Open

fix: remove cfg(production) admin bypass + merge pass pool reserves o…#425
0xksure wants to merge 2 commits intometaDAOproject:developfrom
0xksure:fix/high-severity-security-fixes

Conversation

@0xksure
Copy link

@0xksure 0xksure commented Feb 13, 2026

…n cancel

Two HIGH severity security fixes:

  1. Admin functions bypass in non-production mode (FT-F02) All admin functions (admin_remove_proposal, admin_cancel_proposal, admin_approve_execute_multisig_proposal, collect_fees) gate admin key verification behind #[cfg(feature = "production")]. If deployed without the production feature flag, ANY signer can execute admin operations including cancelling active proposals and collecting protocol fees. Fix: Always check admin keys at runtime.

  2. admin_cancel_proposal drops pass pool reserves (FT-F09) When admin cancels a proposal, only fail pool reserves are merged back to spot. Pass pool reserves are silently dropped via Rust's '..' pattern destructure, permanently stranding tokens in the AMM vault. Fix: Also merge pass pool reserves back to spot accounting.

More information https://github.com/0xksure/solana-audit-report/blob/master/PR_BODY_FUTARCHY.md

Max (AI) added 2 commits February 13, 2026 11:12
…n cancel

Two HIGH severity security fixes:

1. Admin functions bypass in non-production mode (FT-F02)
   All admin functions (admin_remove_proposal, admin_cancel_proposal,
   admin_approve_execute_multisig_proposal, collect_fees) gate admin key
   verification behind #[cfg(feature = "production")]. If deployed without
   the production feature flag, ANY signer can execute admin operations
   including cancelling active proposals and collecting protocol fees.
   Fix: Always check admin keys at runtime.

2. admin_cancel_proposal drops pass pool reserves (FT-F09)
   When admin cancels a proposal, only fail pool reserves are merged back
   to spot. Pass pool reserves are silently dropped via Rust's '..' pattern
   destructure, permanently stranding tokens in the AMM vault.
   Fix: Also merge pass pool reserves back to spot accounting.
Full documentation of 2 HIGH severity findings:
- FT-F02: Admin functions bypass in non-production mode
- FT-F09: admin_cancel_proposal drops pass pool reserves

Includes step-by-step reproduction instructions and Anchor test examples.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant