前提條件
網站必須是root權限
需要知道網站的絕對路徑
GPC爲off,php主動轉義的功能關閉
My.ini secure_file_priv=""
文件操作
–file-read #讀取指定文件
–file-write #寫入本地文件
–file-dest #要寫入的文件絕對路徑
命令執行
–os-cmd=whoami #執行系統命令
–os-shell #系統交互shell
和msf的結合
–os-pwn #反彈shell(–os-pwn --msf-path=/opt/framework/msf3/)
原理剖析
Sqlmap會傳上去兩個文件來自動上傳文件,自動執行命令。