[Mono-dev] SslStream X509 certificate
lorenzo.delana
lorenzo.delana at gmail.com
Wed Sep 2 18:17:38 UTC 2015
I'm struggling to find a way to run a SSL server on Linux using mono,
I have a certificate with a private key installed using certmgr and I can
see by listing that the certificate is in the store with Private Key: True
The same client/server code on windows works if I install the certificate
key in Personal store but using mono I keep getting follow error when client
connects the sever
System.IO.IOException: The authentication or decryption has failed. --->
Mono.Security.Protocol.Tls.TlsException: Server certificate Private Key
unavailable.
An example client/server can be found at
https://msdn.microsoft.com/en-us/library/system.net.security.sslstream(v=vs.110).aspx
I also tried to inspect all certificates available in the store with follow
code
var types = new StoreName[]
{
StoreName.Root,
StoreName.TrustedPeople,
StoreName.TrustedPublisher,
StoreName.CertificateAuthority,
StoreName.AuthRoot,
StoreName.AddressBook,
StoreName.Disallowed
};
foreach (var x in types)
{
var store = new
System.Security.Cryptography.X509Certificates.X509Store(x);
Console.WriteLine($"store
cnt={store.Certificates.Count}");
foreach (var y in store.Certificates)
{
Console.WriteLine($"CERT=[{y.FriendlyName}]");
}
}
and results nothing for any store name used.
Some direction to solve this problem ?
thx
--
View this message in context: http://mono.1490590.n4.nabble.com/SslStream-X509-certificate-tp4666570.html
Sent from the Mono - Dev mailing list archive at Nabble.com.
More information about the Mono-devel-list
mailing list