Learning to map source code to software vulnerability using code-as-a-graph

06/15/2020
by   Sahil Suneja, et al.
0

We explore the applicability of Graph Neural Networks in learning the nuances of source code from a security perspective. Specifically, whether signatures of vulnerabilities in source code can be learned from its graph representation, in terms of relationships between nodes and edges. We create a pipeline we call AI4VA, which first encodes a sample source code into a Code Property Graph. The extracted graph is then vectorized in a manner which preserves its semantic information. A Gated Graph Neural Network is then trained using several such graphs to automatically extract templates differentiating the graph of a vulnerable sample from a healthy one. Our model outperforms static analyzers, classic machine learning, as well as CNN and RNN-based deep learning models on two of the three datasets we experiment with. We thus show that a code-as-graph encoding is more meaningful for vulnerability detection than existing code-as-photo and linear sequence encoding approaches. (Submitted Oct 2019, Paper #28, ICST)

READ FULL TEXT

page 1

page 2

page 3

page 4

research
05/23/2023

Sequential Graph Neural Networks for Source Code Vulnerability Identification

Vulnerability identification constitutes a task of high importance for c...
research
09/08/2019

Devign: Effective Vulnerability Identification by Learning Comprehensive Program Semantics via Graph Neural Networks

Vulnerability identification is crucial to protect the software systems ...
research
09/07/2021

Software Vulnerability Detection via Deep Learning over Disaggregated Code Graph Representation

Identifying vulnerable code is a precautionary measure to counter softwa...
research
06/11/2020

Backdoors in Neural Models of Source Code

Deep neural networks are vulnerable to a range of adversaries. A particu...
research
12/16/2020

A Hybrid Graph Neural Network Approach for Detecting PHP Vulnerabilities

This paper presents DeepTective, a deep learning approach to detect vuln...
research
12/29/2022

Meta-Path Based Attentional Graph Learning Model for Vulnerability Detection

In recent years, deep learning (DL)-based methods have been widely used ...
research
05/16/2019

Inferring Javascript types using Graph Neural Networks

The recent use of `Big Code' with state-of-the-art deep learning methods...

Please sign up or login with your details

Forgot password? Click here to reset