title: Calling a webservice "The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel"
body: <p>There are many versions of this question on stackoverflow. I have tried a lot of the solutions suggested there - but none of these work for me.</p>
  
  <p>I have a VB ASP.NET application running on IIS on Windows Server 2008. It calls a webservice. The Server running the Web Service has a self signed certificate. I have imported the Cert into the Trust Store of the IIS machine. I can see the certificate in IE->Options->Content->Certificates->Trusted Root Certification Authorities.</p>
  
  <p>When the webservice is called, an exception is thrown </p>
  
  <blockquote>
    <p>The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.</p>
  </blockquote>
  
  <p>The same IIS VB ASP.NET Application runs fine on another machine with a similar setup.</p>
  
  <p>These are the different basic things I have checked</p>
  
  <ul>
  <li>The URL used to call the webservice is the same as the CN on the Cert imported into the Trusted Root CA.</li>
  <li>Time is synced between the calling machine and the webservice host</li>
  <li>The Cert isn't expired.</li>
  <li>The IIS machine has Proxy settings in IIS, but Webservice Host machine as added to list of exceptions where Proxy should not be used.</li>
  </ul>
  
  <p>I wrote a small command line test program in VB.NET calling the same webservice which runs fine.</p>
  
  <p>After importing the Cert into the Trusted CA store, I have done a iisreset.</p>
  
  <p>Only thing I haven't tried yet is rebooting the IIS machine - this is production machine &amp; I cannot reboot it for at least a couple of days.</p>
  
  <p>What else can I try?</p>