Enhancing SQL Injection Detection: A Machine Learning Approach Using Network Flow Data
P. Vinoth1, K. Muthamil Sudar1 & S. Muthukumar1 Show affiliations
- Department of Computer Science and Engineering, Mepco Schlenk Engineering College, Sivakasi, Tamil Nadu 626005, India
Journal of Computer Science, Volume 22, Issue 8, pp. 2484–2502 · doi.org/10.3844/jcssp.2026.2484.2502
Abstract
Background: SQL injection is one of the cyberattacks which occurs in web application vulnerabilities. It targets the poor input validation and enables the attackers to inject malicious queries into the database fields in any application. It will grant access to unauthorized users and data modification, or they will take control over the complete database. To prevent this, there are several traditional methods, like Intrusion Detection Systems (IDS) and packet inspection methods, which will detect these attacks by each and every network packet in the network traffic. Methods: The existing methods also have some limitations due to computational overhead due to monitoring each and every packet. It makes it challenging for high-end routers and large-scale networks as it monitors all the individual traffic. To resolve this problem, propose a flow-based detection method, making use of lightweight protocols like NetFlow and sFlow to identify SQLI attacks. Unlike traditional methods, which require more inspection on individual packets, flow-based analysis uses mandatory communication metadata, like source and destination IP addresses, port numbers, etc. It minimizes the need for computationally expensive packet inspection, which is going to render the process of detection more trustworthy and economical, particularly within high-traffic conditions. Results: In order to validate this approach, we gathered two collections of data, which included net flow data of SQLI attacks of database systems such as SQL, postgres SQL, etc. It has both normal and bad traffic, and we applied machine learning models to the traffic. Conclusion: The results indicate that the proposed flow-based method is more efficient and scalable for detecting SQL injection attacks than packet-based inspection.
Licence and reuse
Open access. This article is licensed under a Creative Commons Attribution 4.0 International Licence (CC BY 4.0), as printed on the article, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original authors and the source. No permission is needed.
How to reuse this articleResponses (0)
About this article
Vinoth, P., Sudar, K. M. & Muthukumar, S. (2026). Enhancing SQL Injection Detection: A Machine Learning Approach Using Network Flow Data. Journal of Computer Science, 22(8), 2484–2502. https://doi.org/10.3844/jcssp.2026.2484.2502
- Licence
- CC BY 4.0
- Issue
- Volume 22, Issue 8
- Policies
- Editorial independenceUse of generative AIData availabilityAppeals and complaints
- Version
- Version of record
