PeakDeFi exploited for $33.8K via flash-loan referral commission manipulation; attacker borrowed 50M USDC from Morpho to inflate fund balances and claim unearned referral fees.
Security & Exploits ·
PeakDeFi suffered a loss of approximately $33.8K through a flash-loan attack targeting its referral commission system. An attacker flash-borrowed 50M USDC from Morpho and deposited the funds into the PeakDeFiFund contract while registering an attacker-controlled contract as a referrer. The protocol's commission redemption logic immediately calculated and paid out referral fees based on the temporarily inflated fund balance, distributing approximately $33.8K in USDC to the attacker's referrer contract and its upstream chain.
The exploit exposed a timing vulnerability in how the protocol computed referral commissions. Rather than requiring deposits to persist over a meaningful period, the redemption mechanism calculated payouts based on account balances at the moment of claim, allowing a single-block flash loan to generate legitimate-appearing commission withdrawals. After the initial deposit triggered the commission payout, the attacker withdrew the full 50M USDC, repaid the Morpho flash loan, and converted a portion of profits to other assets.
The attacker retained approximately $15.2K in USDC and 1.07 ETH as net profit. The vulnerability demonstrates a gap between the assumption that referral balances represent genuine capital commitments and the protocol's actual enforcement of that requirement at redemption time. No clarification has yet emerged regarding whether PeakDeFi plans to modify its commission logic or recover funds through other means.