Fine-grained smart contract vulnerability detection by heterogeneous code feature learning and automated dataset construction

智能合约 脆弱性(计算) 抽象语法树 特征(语言学) 编码(集合论) 计算机科学 人工智能 深度学习 语法 图形 机器学习 源代码 计算机安全 理论计算机科学 程序设计语言 集合(抽象数据类型) 哲学 语言学 数据库事务
作者
Jie Cai,Bin Li,Tao Zhang,Jiale Zhang,Xiaobing Sun
出处
期刊:Journal of Systems and Software [Elsevier BV]
卷期号:209: 111919-111919 被引量:3
标识
DOI:10.1016/j.jss.2023.111919
摘要

Recently, several deep learning based smart contract vulnerability detection approaches have been proposed. However, challenges still exist in applying deep learning for fine-grained vulnerability detection in smart contracts, including the lack of the dataset with sufficient statement-level labeled smart contract samples and neglect of heterogeneity between syntax and semantic features during code feature learning. To utilize deep learning for fine-grained smart contract vulnerability detection, we propose a security best practices (SBP) based dataset construction approach to address the scarcity of datasets. Moreover, we propose a syntax-sensitive graph neural network to address the challenge of heterogeneous code feature learning. The dataset construction approach is motivated by the insight that smart contract code fragments guarded by security best practices may contain vulnerabilities in their original unguarded code form. Thus, we locate and strip security best practices from the smart contract code to recover its original vulnerable code form and perform sample labeling. Meanwhile, as the heterogeneity between tree-structured syntax features embodied inside the abstract syntax tree (AST) and graph-structured semantic features reflected by relations between statements, we propose a code graph whose nodes are each statement's AST subtree with a syntax-sensitive graph neural network that enhances the graph neural network by a child-sum tree-LSTM cell to learn these heterogeneous features for fine-grained smart contract vulnerability detection. We compare our approach with three state-of-the-art deep learning-based approaches that only support contract-level vulnerability detection and two popular static analysis-based approaches that support fine detection granularity. The experiment results show that our approach outperforms the baselines at both coarse and fine granularities. In this paper, we propose utilizing security best practices inside the smart contract code to construct the dataset with statement-level labels. To learn both tree-structured syntax and graph-structured semantic code features, we propose a syntax-sensitive graph neural network. The experimental results show that our approach outperforms the baselines.
最长约 10秒,即可获得该文献文件

科研通智能强力驱动
Strongly Powered by AbleSci AI
更新
PDF的下载单位、IP信息已删除 (2025-6-4)

科研通是完全免费的文献互助平台,具备全网最快的应助速度,最高的求助完成率。 对每一个文献求助,科研通都将尽心尽力,给求助人一个满意的交代。
实时播报
ShengzhangLiu发布了新的文献求助10
刚刚
sakitima完成签到 ,获得积分10
1秒前
2秒前
怡然凝云完成签到,获得积分10
3秒前
3秒前
领导范儿应助jdjd采纳,获得10
4秒前
张伟完成签到,获得积分10
6秒前
dz应助泽锦臻采纳,获得10
6秒前
秋刀鱼不过期完成签到 ,获得积分10
9秒前
王铂然完成签到,获得积分10
11秒前
冷静尔芙完成签到,获得积分10
11秒前
peterlee完成签到,获得积分10
11秒前
Hello应助现实的从蓉采纳,获得10
11秒前
13秒前
FashionBoy应助王铂然采纳,获得10
14秒前
14秒前
15秒前
17秒前
温温完成签到,获得积分10
20秒前
21秒前
m1发布了新的文献求助30
21秒前
脑洞疼应助文艺的冬卉采纳,获得10
22秒前
曾建发布了新的文献求助10
22秒前
Mina发布了新的文献求助10
22秒前
wl20130000完成签到,获得积分10
23秒前
来栖完成签到 ,获得积分10
23秒前
张舒涵完成签到,获得积分10
24秒前
26秒前
27秒前
28秒前
28秒前
29秒前
29秒前
30秒前
wcwc12138完成签到,获得积分10
31秒前
jijijibibibi完成签到,获得积分10
31秒前
31秒前
31秒前
xiaojin完成签到,获得积分10
31秒前
LYD完成签到,获得积分10
33秒前
高分求助中
A new approach to the extrapolation of accelerated life test data 1000
Indomethacinのヒトにおける経皮吸収 400
基于可调谐半导体激光吸收光谱技术泄漏气体检测系统的研究 370
Phylogenetic study of the order Polydesmida (Myriapoda: Diplopoda) 370
Robot-supported joining of reinforcement textiles with one-sided sewing heads 320
Aktuelle Entwicklungen in der linguistischen Forschung 300
Current Perspectives on Generative SLA - Processing, Influence, and Interfaces 300
热门求助领域 (近24小时)
化学 材料科学 医学 生物 工程类 有机化学 生物化学 物理 内科学 纳米技术 计算机科学 化学工程 复合材料 遗传学 基因 物理化学 催化作用 冶金 细胞生物学 免疫学
热门帖子
关注 科研通微信公众号,转发送积分 3991883
求助须知:如何正确求助?哪些是违规求助? 3533014
关于积分的说明 11260344
捐赠科研通 3272297
什么是DOI,文献DOI怎么找? 1805688
邀请新用户注册赠送积分活动 882609
科研通“疑难数据库(出版商)”最低求助积分说明 809425