Fiddler Ideas

The free web debugging proxy for any browser, system or platform.

Document steps to install Fiddler Certificate inside of a Linux Docker image

Running .Net Core 2.0 app that issues client requests from inside a Docker container, it is very useful to set up a trace of exactly what the requests/responses look like, including headers.

It is very easy to point the C# code at Fiddler's 8888 proxy, but I get a The certificate chain was issued by an authority that is not trusted for pipe error on the connect.

Fiddler works fine, of course, if I run outside of the Docker container.

 

Please document the steps to add the root certificate into a docker image.  Also document how to integrate this with the Visual Studio support for developing applications running in Docker.

 

Using Flurl.Http:

 

FlurlHttp.Configure(settings => {
settings.HttpClientFactory = new ProxyHttpClientFactory(proxy); // e.g. "http://localhost:8888");
});

List<string> values = new List<string>() { "v1", "v2" };
var responseString = uri.PostJsonAsync(values).ReceiveString().Result;

 

  • Guest
  • Mar 10 2018
  • Under review
  • Attach files
  • Eric Lawrence commented
    March 15, 2018 22:29

    I'm not sure I understand the scenario here... Is Fiddler running inside the container or outside of the container? Is the client application inside the container? You can get Fiddler's certificate from https://localhost:8888/fiddlerroot.cer, and use the appropriate commands to configure the OS to trust it.