r0oth3x49 / ghauri

An advanced cross-platform tool that automates the process of detecting and exploiting SQL injection security flaws
MIT License
3.11k stars 310 forks source link

cant inject x-forward-host ?? #132

Closed evilcode1 closed 6 months ago

evilcode1 commented 8 months ago

i saved my req. from burp :

GET / HTTP/2
Host: target.com
X-Forwarded-Host: *
Sec-Ch-Ua-Platform: "Linux"
Upgrade-Insecure-Requests: 1
User-Agent: 
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7
Sec-Fetch-Site: none
Sec-Fetch-Mode: navigate
Sec-Fetch-User: ?1
Sec-Fetch-Dest: document
Accept-Encoding: gzip, deflate, br
Accept-Language: en-US,en;q=0.9
Priority: u=0, i

the command :

ghauri -r in.txt --technique="TS" --dbs

the error :

[*] starting @ 09:13:17 /2024-03-01/

[09:13:17] [INFO] parsing HTTP request from 'in.txt'
[09:13:17] [CRITICAL] no parameter(s) found for testing in the provided data (e.g. GET parameter 'id' in 'www.site.com/index.php?id=1')

[*] ending @ 09:13:17 /2024-03-01/

any help ??

SRZEUS1990 commented 8 months ago

Same issue, There should be a way to inform the tool which parts of the request should be targeted for injection. This issue also exists for the --headers="Sec-Fetch-Dest:1\n Sec-Fetch-Mode:1 flag.

[11:08:30] [TRAFFIC_OUT] HTTP request [#43]:
GET /?s=admin'%20OR%20NOT%2005218=5150--%20wXyW HTTP/1.1
Xauthorization:1*
Xonnection:1*
Xpdb-Debugger:1*
Xproxy:1*
Xroxy-Connection:1*
Xxx-Real-Ip:1*
Xxxxxxxxxxxxxxx:1*
Y:1*

Even after including many headers, the tool failed to insert any payloads.

mastercho commented 7 months ago

Tested and confirmed, the issue exists