6
votes

I have setup a HttpWebRequest using HTTPS and the code is working fine when Fiddler is running.

When Fiddler isn't running - I get a "request timeout" error.

Does anyone have any ideas what would be the cause? I have

a) Ensured that security policy exists as per

if (this.IngoreCertificateErrors)
    ServicePointManager.ServerCertificateValidationCallback +=
        delegate(object sender, X509Certificate certificate, X509Chain chain,
        SslPolicyErrors sslPolicyErrors)
    { return true; };

b) I have also ensure no firewall conflicts etc

What else can I try?

Edit: Just to be clear - my app basically logins to a website to get a report. On steps 1-3) login, get urls for login and report. Step 4) once logged in - get report. The problem I have is that Step 4) ONLY works with fiddler ?

2
Does it work with HTTP without Fiddler?John Saunders
Hi John - I basically have 4 requests in order to grab a report off a website. These steps are 1-3 login, get urls for login and report 4) once logged in - get report 1-3 works with or without fiddler and 4 only works WITH fiddler?Frederick
Did you ever find a solution to this? I'm having exactly the same problem... (Windows 2008 Server, running virtual under Parallels on OSX, .NET) 3.5Scrappydog

2 Answers

8
votes

Just found the solution for my identical? problem on another thread:

Why does the performance of the HttpWebRequest object improve while using Fiddler?

Adding the following to app.config has my app running happily:

  <system.net>
    <connectionManagement>
      <add address="*" maxconnection="30" />
    </connectionManagement>
  </system.net>

So this makes me think that I am missing some house cleaning in my code and open connections are not getting closed.

1
votes

Check Internet settings on the machine, have the Fiddler proxy setting accidentally been left in place?

Check the application .Config do you have network proxy settings pointing at the Fiddler tool?