Safeguarding DeFi Smart Contracts against Oracle Deviations

Authors:
  • XDXun Deng
    Xun Deng
  • SBSidi Mohamed Beillahi
    Sidi Mohamed Beillahi
  • CMCyrus Minwalla
    Cyrus Minwalla
  • HDHan Du
    Han Du
  • AVAndreas Veneris
    Andreas Veneris
  • FLFan Long
    Fan Long

Abstract
This paper presents OVer, a framework designed to automatically analyze the behavior of decentralized finance (DeFi) protocols when subjected to a "skewed" oracle input. OVer firstly performs symbolic analysis on the given contract and constructs a model of constraints. Then, the framework leverages an SMT solver to identify parameters that allow its secure operation. Furthermore, guard statements may be generated for smart contracts that may use the oracle values, thus effectively preventing oracle manipulation attacks. Empirical results show that OVer can successfully analyze all 10 benchmarks collected, which encompass a diverse range of DeFi protocols. Additionally, this paper also illustrates that current parameters utilized in the majority of benchmarks are inadequate to ensure safety when confronted with significant oracle deviations.
All Related Versions