Neutron: an attention-based neural decompiler
Open Access
- 5 March 2021
- journal article
- research article
- Published by Springer Nature in Cybersecurity
- Vol. 4 (1) , 1-13
Abstract
Decompilation aims to analyze and transform low-level program language (PL) codes such as binary code or assembly code to obtain an equivalent high-level PL. Decompilation plays a vital role in the cyberspace security fields such as software vulnerability discovery and analysis, malicious code detection and analysis, and software engineering fields such as source code analysis, optimization, and cross-language cross-operating system migration. Unfortunately, the existing decompilers mainly rely on experts to write rules, which leads to bottlenecks such as low scalability, development difficulties, and long cycles. The generated high-level PL codes often violate the code writing specifications. Further, their readability is still relatively low. The problems mentioned above hinder the efficiency of advanced applications (e.g., vulnerability discovery) based on decompiled high-level PL codes.In this paper, we propose a decompilation approach based on the attention-based neural machine translation (NMT) mechanism, which converts low-level PL into high-level PL while acquiring legibility and keeping functionally similar. To compensate for the information asymmetry between the low-level and high-level PL, a translation method based on basic operations of low-level PL is designed. This method improves the generalization of the NMT model and captures the translation rules between PLs more accurately and efficiently. Besides, we implement a neural decompilation framework called Neutron. The evaluation of two practical applications shows that Neutron’s average program accuracy is 96.96%, which is better than the traditional NMT model.Keywords
Funding Information
- National Natural Science Foundation of China (U1836211)
This publication has 19 references indexed in Scilit:
- How far we have come: testing decompilation correctness of C decompilers2020
- Using recurrent neural networks for decompilation2018
- VulDeePecker: A Deep Learning-Based System for Vulnerability Detection2018
- Machine-Learning-Guided Selectively Unsound Static Analysis2017
- A Neural Architecture for Generating Natural Language Descriptions from Source Code Changes2017
- Effective Approaches to Attention-based Neural Machine Translation2015
- PsybOt malware: A step-by-step decompilation case study2013
- Stochastic superoptimizationACM SIGARCH Computer Architecture News, 2013
- Long Short-Term MemoryNeural Computation, 1997
- Gradient calculations for dynamic recurrent neural networks: a surveyIEEE Transactions on Neural Networks, 1995