Security context

What an agent needs to avoid regressing past fixes and find the next vuln in this repo.

balancer/balancer-v3-monorepo
main @ 449f7e0
37
Fixes
0
CVEs
CRITICAL
Peak severity
42.4%
Coverage
Highlights
Denial of Service: 7 prior fixes. Scrutinize any change in this area.
pkg/vault/contracts/Vault.sol: most-fixed (9 issues). Treat as high-risk during review.
21 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns

The bug types that recur here, drawn from past fixes, not open vulnerabilities.

Price Manipulation: Multiple fixes address price manipulation through oracle price validation, disabling getRate for weighted pools, invariant ratio guardrails, ERC4626 rate linearity checks, and dynamic fee caps. Attackers could manipulate prices to extract value from pools.
Rounding/Accounting: Rounding errors in invariant, balance, and fee scaling calculations could be exploited for financial gain. Fixes adjust rounding direction (e.g., rounding up rates) to prevent underflow and token theft.
Auth Bypass: Authorization bypasses in admin functions, fee sweeper, MEV tax exemption, and vault pause logic could allow unauthorized control or fee manipulation. Fixes add role checks, delegatecall restrictions, and timestamp conditions.