Cannot load certificate from cerificate store using Thumbprint

This is what I have for the settings:

var samlConfiguration = new SAMLConfiguration
{
LocalServiceProviderConfiguration = new LocalServiceProviderConfiguration()
{
Name = “test_site”,
Description = “test_site”,
AssertionConsumerServiceUrl = “~/test/acs”,
LocalCertificateThumbprint = “‎427a3d5b39df593b1d44b769d3697aedf00fd83f”
}
};


I am getting this exception

ComponentSpace.SAML2.Exceptions.SAMLCertificateException occurred
HResult=0x80131600
Message=The X.509 certificate with find type: FindByThumbprint and find value: ‎427a3d5b39df593b1d44b769d3697aedf00fd83f could not be found in the X.509 store LocalMachine.
Source=ComponentSpace.SAML2
StackTrace:
at ComponentSpace.SAML2.Certificates.CertificateLoader.LoadCertificateFromStore(StoreLocation storeLocation, X509FindType findType, Object findValue)


If I try this is in a stand alone app it seems to be working fine

X509Store store = new X509Store(StoreName.My, StoreLocation.LocalMachine);
store.Open(OpenFlags.ReadOnly);
X509Certificate2Collection certs = store.Certificates.Find(X509FindType.FindByThumbprint, “427a3d5b39df593b1d44b769d3697aedf00fd83f”, false);
store.Close();


Any idea what is going on?



We do essentially the same as the code you have.
Is it possible the string includes some non-printing characters?
Could you copy the string from your test app to the saml.config to see if that works?
If there’s still an issue, please contact us by email including your saml.config file as an email attachment.

[quote]
ComponentSpace - 7/25/2017
We do essentially the same as the code you have.
Is it possible the string includes some non-printing characters?
Could you copy the string from your test app to the saml.config to see if that works?
If there's still an issue, please contact us by email including your saml.config file as an email attachment.
[/quote]

I tried specifying serial number and it worked. Will try saml.config soon.

Ok, thanks for the update.