title: Cannot find the certificate in either the LocalMachine store or the CurrentUser store - Remote Certificate Name Mismatch
body: <p>I'm trying to consume a Mocked WebService created in SoapUI in my C# App but I get this error in the tracing :</p>
  
  <blockquote>
    <p>System.Net Information: 0 : [6756] SecureChannel#40583687 - Cannot find the certificate in either the LocalMachine store or the CurrentUser store.</p>
  </blockquote>
  
  <p>I followed this procedure to create the certificate : 
  <a href="http://www.soapui.org/Service-Mocking/securing-mockservices-with-ssl.html" rel="nofollow noreferrer">SoapUI Mock Services</a></p>
  
  <p>This works fine on SoapUI but when I'm trying to access it via IE11 (<code>https://localhost:8443/test?WSDL</code>), it says there is a problem with the certificate. I continue, install it in the personal folder (&amp; in the Trusted Root Cert Auth to be sure).
  This is weird because even if I just installed the certificate with IE11, when I'm trying to relaod the WS in a new page, it shows me the same security error page ...
  The certificate is present when I check in the MMC (Certificate -> current user).
  I use the Thumbprint to identify the certificate in my C# app and it is recognized. I'm sure of it because I tried to set a bad Thumbprint and I get this error : </p>
  
  <blockquote>
    <p>Cannot find the X.509 certificate using the following search criteria : ....</p>
  </blockquote>
  
  <p>So now i'm getting this in my log file :</p>
  
  <blockquote>
    <p>System.Net Information: 0 : [6756] SecureChannel#40583687 - Cannot find the certificate in either the LocalMachine store or the CurrentUser store.<br>
    ...<br></p>
    
    <p>System.Net Information: 0 : [6756] SecureChannel#40583687 - Remote certificate has errors:<br>
    System.Net Information: 0 : [6756] SecureChannel#40583687 -     Certificate name mismatch.<br>
    System.Net Information: 0 : [6756] SecureChannel#40583687 - Remote certificate was verified as invalid by the user.<br>
    System.Net Error: 0 : [6756] Exception in HttpWebRequest#12123890:: - The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel..<br>
    System.Net Error: 0 : [6756] Exception in HttpWebRequest#12123890::GetResponse - The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel..<br></p>
  </blockquote>
  
  <p>I'm really stuck with this ... Any idea ?</p>
  
  <p>EDIT : I tried the Visual Studio's Web Browser and i get this :
  <img src="https://i.stack.imgur.com/wHaz2.jpg" alt="enter image description here"></p>