CODE INJECTION ATTACK PREVENTION WITH AI-INTEGRATED MACHINE LEARNING APPROACH USING CNN - Shaik, Abdul Subhahan; Shaik, Amjan (ShodhKosh: Journal of Visual and Performing Arts, 2022)
In the ever-evolving landscape of cybersecurity, code injection attacks pose a significant threat to the integrity and security of software applications. This paper introduces an innovative approach to preventing code injection attacks by integrating artificial intelligence (AI) and machine learning techniques, specifically leveraging Convolutional Neural Networks (CNN). The proposed method focuses on the development of a robust model capable of effectively identifying code injection attempts in real time, thereby fortifying applications against malicious exploits. The methodology begins with the preparation of a comprehensive dataset containing legitimate code snippets and injected code samples simulating common attack scenarios. Feature extraction involves the utilization of character-level n-grams or embeddings to capture the syntactic nuances of code. A CNN architecture is designed to take advantage of its ability to recognize local patterns within the code, providing a deeper understanding of the structure and context. The model is trained using the prepared dataset, employing binary classification to distinguish between legitimate and potentially injected code. The integration of this trained model into the application’s security module enables real-time monitoring of incoming code snippets. A threshold is set on the model’s output probability to determine when to flag a code snippet as potentially malicious, allowing for customization based on the application’s security requirements.