Enhancing Java Web Application Security: Injection Vulnerability Detection via Interprocedural Analysis and Deep Learning
- 7 January 2025
- journal article
- research article
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Reliability
- Vol. 74 (3) , 3642-3656
Abstract
Injection attacks exploit vulnerabilities in how applications handle user input, allowing malicious code to infiltrate the execution environment of web applications, leading to severe consequences, such as data leaks and system crashes. Traditional dynamic and static detection methods suffer from limitations in manual rule or pattern design and intraprocedural analysis, lacking the capability to automatically learn complex features. Meanwhile, deep learning models encounter challenges, such as feature redundancy and inefficiency, in processing long code sequences. Here, we propose a prototype for detecting I njection V ulnerabilities in Java web applications based on I nterprocedural analysis and the bidirectional encoder representations from transformers B ERT-BiLSTM-CRF model (IVIB), effectively transforming vulnerability detection into text sequence annotation. IVIB employs interprocedural analysis to trace complete program data flow, control flow, method and class dependencies, reducing redundancy through a system dependency graph. Then, we develop intermediate language representation rules and conversion mechanisms specifically for Java programs, symbolically representing code snippets and annotating them to construct a corpus. IVIB achieves remarkable results, with over 96% accuracy, precision, recall, and F1-score in binary classification, surpassing other state-of-the-art models in multiclassification performance. Evaluation on real-world projects demonstrates IVIB's effectiveness, detecting 28 vulnerabilities out of 30 vulnerable slices with low false positives and no false negatives.Keywords
Funding Information
- National Natural Science Foundation of China (62376240)
- S&T Program of Hebei (226Z0701G, 236Z0702G, 236Z0304G)
- Natural Science Foundation of Hebei Province (F2022203026, F2022203089, F2023203026)
- Basic Innovation Research Cultivation Program of Yanshan University (2024LGZD004)
- Science and Technology Project of Hebei Education Department (BJK2022029)
- Innovation Capability Improvement Plan Project of Hebei Province (22567637H)
This publication has 43 references indexed in Scilit:
- Comprehensive vulnerability aspect extractionApplied Intelligence, 2024
- Milo: Attacking Deep Pre-trained Model for Programming Languages Tasks with Anti-analysis Code Obfuscation2023
- BejaGNN: behavior-based Java malware detection via graph neural networkThe Journal of Supercomputing, 2023
- Systematic Analysis of Deep Learning Model for Vulnerable Code Detection2022
- Software Vulnerability Analysis and Discovery Using Deep Learning Techniques: A SurveyIEEE Access, 2020
- Towards a Deep Learning Model for Vulnerability Detection on Web Application Variants2020
- The impact factors on the performance of machine learning-based vulnerability detection: A comparative studyJournal of Systems and Software, 2020
- An Empirical Study of High-Impact Factors for Machine Learning-Based Vulnerability Detection2020
- Project Achilles: A Prototype Tool for Static Method-Level Vulnerability Detection of Java Source Code Using a Recurrent Neural Network2019
- Automated Vulnerability Detection in Source Code Using Deep Representation Learning2018