Research Article

Deep Learning in Cybersecurity: A Hybrid BERT–LSTM Network for SQL Injection Attack Detection

Table 5

Detection results of the model for different payloads.

PayloadDescriptionDetection results

id = 1 union select 1,2,group_concat (table_name), 3 from information_schema.tables where table_schema = database()Union select injectionsMalicious
id = 1 and ascii(substr (database(),1,1)) > 114Boolean-based BLIND injectionsMalicious
id = 1 and if (ascii(substr (database(),1,1)) > 114, sleep (3),null)Time-based BLIND injectionstMalicious
id = 1 union select 1,2,”<?php @eval ($_GET[‘string’])?>” into outfile xxx.phpWebshellMalicious
id = 1^ (ascii (mid ((select (GROUP_CONCAT (TABLE_NAME))from (information_schema.TABLES)where (TABLE_SCHEMA = database())),1,1)) = 1) = ’1Bypassing blacklist filters stripping SPACESMalicious
Set @a = concat (‘selec’,‘t from xxx’); prepare h from @a; execute @a;Stacked SQL injectionsMalicious
Set @a = 0x73656c656374202a2066726f6d20787878;prepare h from @a;execute @a;Stacked SQL injections and hexadecimal execution bypasses string filteringNormal1
?id = −1 union select group_concat (`123`),2 from (select 123 union select from flag)aBypassing blacklist filters stripping ORMalicious
id = 1 unionunion selectselect 1,2,group_concat (table_name),3 from information_schema.tables where table_schema = database()Double writing bypasses UNION and SELECT filteringMalicious
M!T!@MzIGF.@[email protected].@[email protected]@[email protected]@.zZXI!oKSksM!S!.k. = Insert special characters “!, @,.” in based64 encoding to bypass string filteringNormal1
Select and union and order byBenign statements embedding potentially harmful wordsNormal
<script >alert (document.cookie);</script >XSSNormal1

1The results indicate that the predicted result is opposite to the actual situation.