The invention provides an intelligent contract
vulnerability detection method based on a graph neural network, and the method comprises the steps: extracting a
program control flow diagram and an
abstract syntax diagram from an intelligent contract code, inputting the
program control flow diagram and the
abstract syntax diagram into the graph neural network, converting the
program control flow diagram and the
abstract syntax diagram into high-dimensional feature vectors, and carrying out the classification. The intelligent contract
vulnerability detection taking the contract
source code and the
byte code as input is realized; for a contract without a
source code deployed on a block chain, intelligent contract
vulnerability detection only for an intelligent contract EVM
byte code is realized; compared with a traditional
static analysis method, one of the biggest advantages is that the operation speed is high, and the method has high detection efficiency under the condition that the
detection performance is guaranteed; meanwhile, other existing methods often only research the condition of detecting a single vulnerability, and on the basis of the method, multiple vulnerabilities can be detected at the same time, and good
vulnerability detection performance is achieved only through
byte codes.