Burp Suite User Forum

Create new post

Custom response without forwarded request ?

Bjorn | Last updated: Jul 15, 2016 09:44PM UTC

Hi, I'm intercepting requests from an application and want to return a response based on it, without actually forwarding the request to the original destination. Currently I'm doing it like this: + Intercepting request + Changing target host on GUI and in raw request to i.e. 'google.com' + Select 'Action' -> 'Do intercept' -> 'Response to this request' + Forward request + wait for response + Change raw response to my own content + forward it Is it possible to do it in another way, e.g. with extender API ?

PortSwigger Agent | Last updated: Jul 18, 2016 10:49AM UTC

There isn't currently a neat way to do this, sorry. You can't prevent Burp from actually trying to issue the request. Using the API, you could programatically set the request target to an invalid host, or another webserver that you control, and then change the response as it comes back in.

Burp User | Last updated: Jul 19, 2016 08:01AM UTC

Ok, it works quite well this way. I'm now using a local Python SimpleHTTPServer which responses to all requests.

Burp User | Last updated: Feb 21, 2017 06:19PM UTC

+1 feature request to add response capabilities without sending the request. I recently wrote an extension which responds with my own files to requests, I solved it by adding another proxy listener to burp (8090), redirecting the host to 127.0.0.1:8090 in the request. When the response comes back I change the response to whatever I want and write back the correct host. It is an ugly hack and would love to get a better solution

You must be an existing, logged-in customer to reply to a thread. Please email us for additional support.