Deep Learning-Based Program-Wide Binary Code Similarity for Smart Contracts

被引:0
|
作者
Zhuang, Yuan [1 ]
Wang, Baobao [1 ]
Sun, Jianguo [2 ]
Liu, Haoyang [1 ]
Yang, Shuqi [1 ]
Ma, Qingan [3 ]
机构
[1] Harbin Engn Univ, Harbin 150000, Peoples R China
[2] Univ Sanya, Sanya 572000, Peoples R China
[3] Univ Alberta, Edmonton, AB T5J 4P6, Canada
来源
CMC-COMPUTERS MATERIALS & CONTINUA | 2023年 / 74卷 / 01期
关键词
Smart contract; similarity detection; neural network;
D O I
10.32604/cmc.2023.028058
中图分类号
TP [自动化技术、计算机技术];
学科分类号
0812 ;
摘要
Recently, security issues of smart contracts are arising great atten-tion due to the enormous financial loss caused by vulnerability attacks. There is an increasing need to detect similar codes for hunting vulnerability with the increase of critical security issues in smart contracts. Binary similarity detection that quantitatively measures the given code diffing has been widely adopted to facilitate critical security analysis. However, due to the difference between common programs and smart contract, such as diversity of bytecode generation and highly code homogeneity, directly adopting existing graph matching and machine learning based techniques to smart contracts suffers from low accuracy, poor scalability and the limitation of binary similarity on function level. Therefore, this paper investigates graph neural network to detect smart contract binary code similarity at the program level, where we conduct instruction-level normalization to reduce the noise code for smart contract pre-processing and construct contract control flow graphs to represent smart contracts. In particular, two improved Graph Convolutional Network (GCN) and Message Passing Neural Network (MPNN) models are explored to encode the contract graphs into quantitatively vectors, which can capture the semantic information and the program-wide control flow information with temporal orders. Then we can efficiently accomplish the similarity detection by measuring the distance between two targeted contract embeddings. To evaluate the effectiveness and efficient of our proposed method, extensive experiments are performed on two real-world datasets, i.e., smart contracts from Ethereum and Enterprise Operation System (EOS) blockchain-based platforms. The results show that our proposed approach outperforms three state-of-the-art methods by a large margin, achieving a great improvement up to 6.1% and 17.06% in accuracy.
引用
收藏
页码:1011 / 1024
页数:14
相关论文
共 50 条
  • [21] Similarity-based face image retrieval using sparsely embedded deep features and binary code learning
    Elboushaki, Abdessamad
    Hannane, Rachida
    Afdel, Karim
    INTERNATIONAL JOURNAL OF MULTIMEDIA INFORMATION RETRIEVAL, 2024, 13 (03)
  • [22] When Deep Learning Meets Smart Contracts
    Gao, Zhipeng
    2020 35TH IEEE/ACM INTERNATIONAL CONFERENCE ON AUTOMATED SOFTWARE ENGINEERING (ASE 2020), 2020, : 1400 - 1402
  • [23] A Heuristic Local-sensitive Program-Wide Diffing Method for IoT Binary Files
    Lu Yu
    Yuliang Lu
    Yi Shen
    Zulie Pan
    Hui Huang
    Arabian Journal for Science and Engineering, 2022, 47 : 9713 - 9725
  • [24] A Survey on Deep Learning-Based Source Code Defect Analysis
    Guan, Zhibin
    Wang, Xiaomeng
    Xin, Wei
    Wang, Jiajie
    Zhang, Li
    2020 5TH INTERNATIONAL CONFERENCE ON COMPUTER AND COMMUNICATION SYSTEMS (ICCCS 2020), 2020, : 167 - 171
  • [25] Deep Learning-Based Code Refactoring: A Review of Current Knowledge
    Naik, Purnima
    Nelaballi, Salomi
    Pusuluri, Venkata Sai
    Kim, Dae-Kyoo
    SSRN, 2022,
  • [26] Deep Learning-Based Code Refactoring: A Review of Current Knowledge
    Naik, Purnima
    Nelaballi, Salomi
    Pusuluri, Venkata Sai
    Kim, Dae-Kyoo
    JOURNAL OF COMPUTER INFORMATION SYSTEMS, 2024, 64 (02) : 314 - 328
  • [27] A parallel deep learning-based code clone detection model
    Zhang, Xiangping
    Liu, Jianxun
    Shi, Min
    JOURNAL OF PARALLEL AND DISTRIBUTED COMPUTING, 2023, 181
  • [28] Deep Learning-Based Residual Control Chart for Binary Response
    Kim, Jong Min
    Ha, Il Do
    SYMMETRY-BASEL, 2021, 13 (08):
  • [29] Deep learning-based prediction approaches of binary star parameters
    Helmy, Islam
    Ismail, Mohamed
    Eid, Doaa
    EXPERIMENTAL ASTRONOMY, 2025, 59 (01)
  • [30] Deep learning-based energy inefficiency detection in the smart buildings
    Huang, Jueru
    Koroteev, Dmitry D.
    Rynkovskaya, Marina
    SUSTAINABLE COMPUTING-INFORMATICS & SYSTEMS, 2023, 40