title: Certificate not found on Azure Web App
body: <p>I deployed a web application as a Web App on Azure App Service. 
  I uploaded some certificates to the Azure Portal, since the Web App runs over SSL, and we use another certificate to perform some decryption.</p>
  
  <p>For the latter case I have a method (which works fine locally) to find a certificate: </p>
  
  <pre><code>public static X509Certificate2 FindCertificate(KnownCertificate certificate)
      {
          return FindCertificate(StoreName.My, StoreLocation.CurrentUser, X509FindType.FindByThumbprint, certificate.Thumbprint);
      }
  </code></pre>
  
  <p>But I get an error that the certificate with thumbprint XYZ is not found.  Although, on the Azure Portal it is present. (I had uploaded and imported it)</p>
  
  <p>I am using StoreLocation.CurrentUser as suggested in <a href="https://stackoverflow.com/questions/23827884/accessing-uploaded-certificates-in-azure-web-sites">THIS POST</a> but it still does not work. Am I using the wrong store or what else am I missing?</p>
  
  <p>EDIT: I have managed to remotetly debug my WebApp and with the ImmediateWindow feature of VisualStudio I have executed this code</p>
  
  <pre><code>new X509Store(StoreName.CertificateAuthority, StoreLocation.CurrentUser).Certificates.Find(findType, findValue, false).Count;
  </code></pre>
  
  <p>testing all possible combinations of StoreNames and StoreLocations but to no avail.</p>
  
  <p>Is it possible like stated <a href="https://stackoverflow.com/questions/23827884/accessing-uploaded-certificates-in-azure-web-sites">here</a> that for using certificate with purposes other than https traffic you would need a Cloud Service and that (I suppose that) App Services do not support it?</p>