There is this program I'd like to debug of which I already have the source code.

When I run the program, it sends a post request to a specific URL with JSON data, but it doesn't show up in http debuggers. I have tried Fiddler 4 and HTTP Debugger Pro so far. It also doesn't connect to any proxies. Also, the debuggers capture everything else, so they probably work.

Here is the C# code responsible for the request (the code itself works, but I may have modified some parts to post it here):

WebRequest webRequest = WebRequest.Create("url");
webRequest.Method = "POST";
webRequest.ContentType = "application/json";
byte[] bytes = Encoding.UTF8.GetBytes(("JSON DATA"));
using (Stream requestStream = webRequest.GetRequestStream())
  requestStream.Write(bytes, 0, bytes.Length);
WebResponse response = webRequest.GetResponse();
Stream responseStream;
using (responseStream = response.GetResponseStream())
  string end = new StreamReader(responseStream).ReadToEnd();

Why are none of the http debuggers capturing the request? Any help is appreciated!

  • Sorry but I am a bit confused because you call a proxy like Fiddler a debugger which is very unusual. Fiddler is an Man-in-the-Middle proxy or you can call it an HTTPS intercepting proxy but it is never a debugger. Debuggers connect directly to the process and allow to set break points on certain code points. So are you also using a real debugger to check the program or are you just talking about proxies?
    – Robert
    Jun 23 at 20:24
  • Well, I am talking about proxies in this case, but http debugger pro isn't a proxy, so I don't know what to call it. I am not using debuggers that connect to the process, but rather these requests/network debuggers that check where applications make requests to.
    – Nqndi
    Jun 24 at 5:42

This site is temporarily in read only mode and not accepting new answers.

Browse other questions tagged .