Combining Graph Neural Networks with Expert Knowledge for Smart Contract Vulnerability Detection

07/24/2021
by   Zhenguang Liu, et al.
0

Smart contract vulnerability detection draws extensive attention in recent years due to the substantial losses caused by hacker attacks. Existing efforts for contract security analysis heavily rely on rigid rules defined by experts, which are labor-intensive and non-scalable. More importantly, expert-defined rules tend to be error-prone and suffer the inherent risk of being cheated by crafty attackers. Recent researches focus on the symbolic execution and formal analysis of smart contracts for vulnerability detection, yet to achieve a precise and scalable solution. Although several methods have been proposed to detect vulnerabilities in smart contracts, there is still a lack of effort that considers combining expert-defined security patterns with deep neural networks. In this paper, we explore using graph neural networks and expert knowledge for smart contract vulnerability detection. Specifically, we cast the rich control- and data- flow semantics of the source code into a contract graph. To highlight the critical nodes in the graph, we further design a node elimination phase to normalize the graph. Then, we propose a novel temporal message propagation network to extract the graph feature from the normalized graph, and combine the graph feature with designed expert patterns to yield a final detection system. Extensive experiments are conducted on all the smart contracts that have source code in Ethereum and VNT Chain platforms. Empirical results show significant accuracy improvements over the state-of-the-art methods on three types of vulnerabilities, where the detection accuracy of our method reaches 89.15 89.02 vulnerabilities, respectively.

READ FULL TEXT

page 10

page 14

research
06/17/2021

Smart Contract Vulnerability Detection: From Pure Neural Network to Interpretable Graph Feature and Expert Pattern Fusion

Smart contracts hold digital coins worth billions of dollars, their secu...
research
04/21/2023

Smart Learning to Find Dumb Contracts

We introduce Deep Learning Vulnerability Analyzer (DLVA), a vulnerabilit...
research
07/17/2023

G-Scan: Graph Neural Networks for Line-Level Vulnerability Identification in Smart Contracts

Due to the immutable and decentralized nature of Ethereum (ETH) platform...
research
04/21/2023

Schooling to Exploit Foolish Contracts

We introduce SCooLS, our Smart Contract Learning (Semi-supervised) engin...
research
08/28/2022

MANDO: Multi-Level Heterogeneous Graph Embeddings for Fine-Grained Detection of Smart Contract Vulnerabilities

Learning heterogeneous graphs consisting of different types of nodes and...
research
04/29/2021

A comparative study of neural network techniques for automatic software vulnerability detection

Software vulnerabilities are usually caused by design flaws or implement...
research
06/07/2023

Vulnerable Smart Contract Function Locating Based on Multi-Relational Nested Graph Convolutional Network

The immutable and trustable characteristics of blockchain enable smart c...

Please sign up or login with your details

Forgot password? Click here to reset