ContractFuzzer: Fuzzing Smart Contracts for Vulnerability Detection
arXiv:1807.03932 · doi:10.1145/3238147.3238177
Abstract
Decentralized cryptocurrencies feature the use of blockchain to transfer values among peers on networks without central agency. Smart contracts are programs running on top of the blockchain consensus protocol to enable people make agreements while minimizing trusts. Millions of smart contracts have been deployed in various decentralized applications. The security vulnerabilities within those smart contracts pose significant threats to their applications. Indeed, many critical security vulnerabilities within smart contracts on Ethereum platform have caused huge financial losses to their users. In this work, we present ContractFuzzer, a novel fuzzer to test Ethereum smart contracts for security vulnerabilities. ContractFuzzer generates fuzzing inputs based on the ABI specifications of smart contracts, defines test oracles to detect security vulnerabilities, instruments the EVM to log smart contracts runtime behaviors, and analyzes these logs to report security vulnerabilities. Our fuzzing of 6991 smart contracts has flagged more than 459 vulnerabilities with high precision. In particular, our fuzzing tool successfully detects the vulnerability of the DAO contract that leads to USD 60 million loss and the vulnerabilities of Parity Wallet that have led to the loss of $30 million and the freezing of USD 150 million worth of Ether.
arXiv commentTo appear in ASE 2018, Montpellier, France. 10 pages
Cited by in corpus (78)
- Combining Graph Neural Networks with Expert Knowledge for Smart Contract Vulnerability Detection
- How Effective are Smart Contract Analysis Tools? Evaluating Smart Contract Static Analysis Tools Using Bug Injection
- GPTScan: Detecting Logic Vulnerabilities in Smart Contracts by Combining GPT with Program Analysis
- DEFECTCHECKER: Automated Smart Contract Defect Detection by Analyzing EVM Bytecode
- A comprehensive survey on smart contract construction and execution: paradigms, tools, and systems
- A Survey on Ethereum Systems Security: Vulnerabilities, Attacks and Defenses
- The Security Reference Architecture for Blockchains: Towards a Standardized Model for Studying Vulnerabilities, Threats, and Defenses
- xFuzz: Machine Learning Guided Cross-Contract Fuzzing
- When ChatGPT Meets Smart Contract Vulnerability Detection: How Far Are We?
- Securing Smart Contract On The Fly
- Smart Contract and DeFi Security Tools: Do They Meet the Needs of Practitioners?
- Smart Contract Vulnerabilities: Vulnerable Does Not Imply Exploited
- Reentrancy Vulnerability Identification in Ethereum Smart Contracts
- DAppSCAN: Building Large-Scale Datasets for Smart Contract Weaknesses in DApp Projects
- The Art of The Scam: Demystifying Honeypots in Ethereum Smart Contracts
- ContractGuard: Defend Ethereum Smart Contracts with Embedded Intrusion Detection
- MTFuzz: Fuzzing with a Multi-Task Neural Network
- sFuzz: An Efficient Adaptive Fuzzer for Solidity Smart Contracts
- Attacking the DeFi Ecosystem with Flash Loans for Fun and Profit
- Definition and Detection of Defects in NFT Smart Contracts
- Static Application Security Testing (SAST) Tools for Smart Contracts: How Far Are We?
- TxT: Real-time Transaction Encapsulation for Ethereum Smart Contracts
- SigRec: Automatic Recovery of Function Signatures in Smart Contracts
- Combatting Front-Running in Smart Contracts: Attack Mining, Benchmark Construction and Vulnerability Detector Evaluation
- ESCORT: Ethereum Smart COntRacTs Vulnerability Detection using Deep Neural Network and Transfer Learning
- Precise Attack Synthesis for Smart Contracts
- DeFiRanger: Detecting Price Manipulation Attacks on DeFi Applications
- Fuzz on the Beach: Fuzzing Solana Smart Contracts
- OpenSCV: An Open Hierarchical Taxonomy for Smart Contract Vulnerabilities
- SmartAxe: Detecting Cross-Chain Vulnerabilities in Bridge Smart Contracts via Fine-Grained Static Analysis
- Maintaining Smart Contracts on Ethereum: Issues, Techniques, and Future Challenges
- FlashSyn: Flash Loan Attack Synthesis via Counter Example Driven Approximation
- SmartState: Detecting State-Reverting Vulnerabilities in Smart Contracts via Fine-Grained State-Dependency Analysis
- EVulHunter: Detecting Fake Transfer Vulnerabilities for EOSIO's Smart Contracts at Webassembly-level
- SolidityCheck : Quickly Detecting Smart Contract Problems Through Regular Expressions
- Mutation Testing for Ethereum Smart Contract
- Characterizing EOSIO Blockchain
- A Survey of Smart Contract Formal Specification and Verification
- Penny Wise and Pound Foolish: Quantifying the Risk of Unlimited Approval of ERC20 Tokens on Ethereum
- ÐArcher: Detecting On-Chain-Off-Chain Synchronization Bugs in Decentralized Applications
- Oracle-Supported Dynamic Exploit Generation for Smart Contracts
- sCompile: Critical Path Identification and Analysis for Smart Contracts
- Security Analysis of EOSIO Smart Contracts
- Using Fault Injection to Assess Blockchain Systems in Presence of Faulty Smart Contracts
- An Empirical Study of Blockchain Repositories in GitHub
- A Survey of Security Vulnerabilities in Ethereum Smart Contracts
- UltraFuzz: Towards Resource-saving in Distributed Fuzzing
- XBlock-ETH: Extracting and Exploring Blockchain Data From Ethereum
- WANA: Symbolic Execution of Wasm Bytecode for Cross-Platform Smart Contract Vulnerability Detection
- Identifying Smart Contract Security Issues in Code Snippets from Stack Overflow
- Bug Searching in Smart Contract
- FORAY: Towards Effective Attack Synthesis against Deep Logical Vulnerabilities in DeFi Protocols
- Detecting Standard Violation Errors in Smart Contracts
- Superion: Grammar-Aware Greybox Fuzzing
- Truffle tests for free -- Replaying Ethereum smart contracts for transparency
- Smart Contract Vulnerability Detection: From Pure Neural Network to Interpretable Graph Feature and Expert Pattern Fusion
- sGUARD: Towards Fixing Vulnerable Smart Contracts Automatically
- On the Just-In-Time Discovery of Profit-Generating Transactions in DeFi Protocols
- VeriSmart: A Highly Precise Safety Verifier for Ethereum Smart Contracts
- ADF-GA: Data Flow Criterion Based Test Case Generation for Ethereum Smart Contracts
- Kaya: A Testing Framework for Blockchain-based Decentralized Applications
- Bridging the Gap: A Comparative Study of Academic and Developer Approaches to Smart Contract Vulnerabilities
- Basis Path Coverage Criteria for Smart Contract Application Testing
- Blockchain Testing: Challenges, Techniques, and Research Directions
- Deep Smart Contract Intent Detection
- A Survey on Vulnerabilities of Ethereum Smart Contracts
- OpDiffer: LLM-Assisted Opcode-Level Differential Testing of Ethereum Virtual Machine
- A Framework and DataSet for Bugs in Ethereum Smart Contracts
- Defining Smart Contract Defects on Ethereum
- Time-Travel Investigation: Towards Building A Scalable Attack Detection Framework on Ethereum
- Smart Contract Security: a Practitioners' Perspective
- Fair and autonomous sharing of federate learning models in mobile Internet of Things
- Compositional Verification of Smart Contracts Through Communication Abstraction (Extended)
- Solidity Meets LLMs: A Transformer-Based Approach to Smart Contract Vulnerability Detection
- HFContractFuzzer: Fuzzing Hyperledger Fabric Smart Contracts for Vulnerability Detection
- Understanding the Motivations, Challenges and Needs of Blockchain Software Developers: A Survey
- EchoFuzz: Empowering Smart Contract Fuzzing with Large Language Models
- Automated Test-Case Generation for Solidity Smart Contracts: the AGSolT Approach and its Evaluation