An Efficient Cross-Contract Vulnerability Detection Model Integrating Machine Learning and Fuzz Testing
摘要
Due to the lengthy processing time associated with traditional fuzz testing methods for identifying vulnerable contracts, we have integrated machine learning with improved fuzz testing tools. We employ decision tree, EEC, and random forest models for filtering vulnerable contracts, complemented by an enhanced fuzz testing tool. Starting with the opcode features of smart contracts, we utilize the N-Gram algorithm to extract multidimensional features, assess feature importance using the TF-IWF algorithm, and construct a comprehensive 2312-dimensional feature matrix for training machine learning models to filter cross-contract vulnerabilities. Experimental results demonstrate the robust performance of the model in cross-contract vulnerability detection, successfully identifying 15 new instances of cross-contract reentrancy vulnerabilities with a precision of 93.6% and an F1-Score of 87.5%. A comparison with advanced fuzz testing tools confirms the superiority of our model in cross-contract vulnerability detection.