OJ / gobuster

Directory/File, DNS and VHost busting tool written in Go
Apache License 2.0
9.34k stars 1.16k forks source link

Handle empty response from server #437

Closed ajmeese7 closed 11 months ago

ajmeese7 commented 11 months ago

Similar to #206 , I am encountering the following error:

Error: error on running gobuster: unable to connect to http://myip:myport/: Get "http://myip:myport/": EOF

The web server in question is returning an empty response, but is available to reach out to via curl:

$ curl http://myip:myport/
curl: (52) Empty reply from server

I suspect the server in question is not hosting anything on the root of the IP, but that there are hidden directories that actually contain content and will return a legitimate response, which is why I turned to gobuster to suss it out. Is there a way the tool could be configured to treat an empty response as a normal 404 or something to that effect, instead of assuming that there was a problem connecting to the server?

firefart commented 11 months ago

This normally happens when you talk https to an http port. In this case the server closes the connection without sending any data back, thus not being valid http. Example: curl http://google.com:443

It does not make sense to continue in such a case as all requests will end up like this but I can look into making the error message more user friendly

ajmeese7 commented 11 months ago

Thanks! 🎉