SqliGPT: Evaluating and Utilizing Large Language Models for Automated SQL Injection Black-Box Detection
-
Published:2024-08-07
Issue:16
Volume:14
Page:6929
-
ISSN:2076-3417
-
Container-title:Applied Sciences
-
language:en
-
Short-container-title:Applied Sciences
Author:
Gui Zhiwen1ORCID, Wang Enze1ORCID, Deng Binbin1, Zhang Mingyuan1, Chen Yitao1, Wei Shengfei1, Xie Wei1, Wang Baosheng1
Affiliation:
1. College of Computer, National University of Defense Technology, Changsha 410073, China
Abstract
SQL injection (SQLI) black-box detection, which simulates external attack scenarios, is crucial for assessing vulnerabilities in real-world web applications. However, existing black-box detection methods rely on predefined rules to cover the most common SQLI cases, lacking diversity in vulnerability detection scheduling and payload, suffering from limited efficiency and accuracy. Large Language Models (LLMs) have shown significant advancements in several domains, so we developed SqliGPT, an LLM-powered SQLI black-box scanner that leverages the advanced contextual understanding and reasoning abilities of LLMs. Our approach introduces the Strategy Selection Module to improve detection efficiency and the Defense Bypass Module to address insufficient defense mechanisms. We evaluated SqliGPT against six state-of-the-art scanners using our SqliMicroBenchmark. Our evaluation results indicate that SqliGPT successfully detected all 45 targets, outperforming other scanners, particularly on targets with insufficient defenses. Additionally, SqliGPT demonstrated excellent efficiency in executing detection tasks, slightly underperforming Arachni and SQIRL on 27 targets but besting them on the other 18 targets. This study highlights the potential of LLMs in SQLI black-box detection and demonstrates the feasibility and effectiveness of LLMs in enhancing detection efficiency and accuracy.
Reference52 articles.
1. Guan, Y., He, J., Li, T., Zhao, H., and Ma, B. (2023). SSQLi: A Black-Box Adversarial Attack Method for SQL Injection Based on Reinforcement Learning. Future Internet, 15. 2. Wahaibi, S.A.A., Foley, M., and Maffeis, S. (2023, January 9–11). SQIRL: Grey-Box Detection of SQL Injection Vulnerabilities Using Reinforcement Learning. Proceedings of the USENIX Security Symposium, Anaheim, CA, USA. 3. Djuric, Z. (2013, January 23–25). A black-box testing tool for detecting SQL injection vulnerabilities. Proceedings of the 2013 Second International Conference on Informatics & Applications (ICIA), Lodz, Poland. 4. Fault-based Testing for Discovering SQL Injection Vulnerabilities in Web Applications;Saifan;Int. J. Inf. Comput. Secur.,2018 5. Appelt, D., Nguyen, D.C., Briand, L.C., and Alshahwan, N. (2014, January 21–25). Automated testing for SQL injection vulnerabilities: An input mutation approach. Proceedings of the International Symposium on Software Testing and Analysis, San Jose, CA, USA.
|
|