The registry contract permanently holds staked tokens. If the contract address gets blacklisted by tokens with blacklist functionality (like USDC/USDT), all staked tokens become permanently locked, with no recovery mechanism.
https://github.com/Cyfrin/2024-10-swan-dria/blob/main/contracts/llm/LLMOracleRegistry.sol#L94
Many widely used ERC20 tokens (like USDC, USDT) implement blacklisting functionality where certain addresses can be blocked from transferring tokens. If the registry contract address gets blacklisted:
Any tokens already held by the contract become permanently locked
All registered oracles lose their staked tokens
The unregister function's token approval becomes useless since transfers are blocked
No recovery mechanism exists in the current contract
Real World Example:
An oracle stakes 10,000 USDC to register as a Generator
The registry contract gets blacklisted by USDC (could happen due to regulatory requirements)
Even though the oracle can call unregister(), they can never get their USDC back
The tokens remain locked in the contract forever
Permanent loss of user funds
Contract becomes unusable for that specific token
No remediation possible even by contract owner
All oracles using that token must be considered compromised
Safer Pattern:
Mitigation Strategies:
Implement pull payment pattern for withdrawals
Add ability to change token address in emergencies
Consider multi-token support to spread risk
Add emergency withdrawal functionality for owner
Consider time-locks for large withdrawals
This issue is particularly critical because:
USDC/USDT are likely token choices for staking
Blacklisting is a real and active risk with these tokens
The amounts at stake could be substantial
The contract is designed for long-term staking
Once blacklisted, the loss is irreversible
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.