arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2111.12423cs.CRcs.SE
收藏

xFuzz:机器学习引导的跨合约模糊化

xFuzz: Machine Learning Guided Cross-Contract Fuzzing

Yinxing Xue, Jiaming Ye, Wei Zhang, Jun Sun, Lei Ma, Haijun Wang, Jianjun Zhao

摘要:

智能合约交易越来越多地被交叉合约调用所交织。虽然已经开发了许多工具来识别一组常见的漏洞,但现有工具忽略了跨合同漏洞。跨合约漏洞是指存在两个以上交互合约时出现的可利用漏洞。然而,现有的方法仅限于同时分析最多两个合同。检测跨合约漏洞是非常重要的。多个交互合约的搜索空间比单个合约的搜索空间大得多。为了解决这个问题,我们提出了xFuzz,一个机器学习引导的智能合约模糊框架。机器学习模型用新特征(例如,字向量和指令),并用于过滤可能的良性程序路径。与现有的静态工具相比,机器学习模型具有更强的鲁棒性,避免了在特定工具中直接采用人工定义的规则。我们将xFuzz与三种最先进的工具在7,391份合同上进行了比较。xFuzz检测到18个可利用的跨合约漏洞,其中15个漏洞为首次曝光。此外,我们的方法被证明在检测非交叉合同漏洞方面也很有效-使用不到20%的时间作为其他模糊工具,xFuzz检测到两倍的漏洞。

英文摘要:

Smart contract transactions are increasingly interleaved by cross-contract calls. While many tools have been developed to identify a common set of vulnerabilities, the cross-contract vulnerability is overlooked by existing tools. Cross-contract vulnerabilities are exploitable bugs that manifest in the presence of more than two interacting contracts. Existing methods are however limited to analyze a maximum of two contracts at the same time. Detecting cross-contract vulnerabilities is highly non-trivial. With multiple interacting contracts, the search space is much larger than that of a single contract. To address this problem, we present xFuzz, a machine learning guided smart contract fuzzing framework. The machine learning models are trained with novel features (e.g., word vectors and instructions) and are used to filter likely benign program paths. Comparing with existing static tools, machine learning model is proven to be more robust, avoiding directly adopting manually-defined rules in specific tools. We compare xFuzz with three state-of-the-art tools on 7,391 contracts. xFuzz detects 18 exploitable cross-contract vulnerabilities, of which 15 vulnerabilities are exposed for the first time. Furthermore, our approach is shown to be efficient in detecting non-cross-contract vulnerabilities as well -- using less than 20% time as that of other fuzzing tools, xFuzz detects twice as many vulnerabilities.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑