im trying to transfer the code from the console application to uwp, in this console application the ServicePointManager is used, which uses all the certificates, in the uwp application I donโt use them and I have no exception with the text - โUnable to establish connection with the serverโ.
Question: how can I replace ServicePointManager and apply all certificates in uwp (because I do not know what type of certificate is used for this server).
ServicePointManager code is below:
ServicePointManager.ServerCertificateValidationCallback += new System.Net.Security.RemoteCertificateValidationCallback (bypassAllCertificateStuff); private static bool bypassAllCertificateStuff(object sender, X509Certificate cert, X509Chain chain, System.Net.Security.SslPolicyErrors error) { return true; }
Thanks for the answer!
source share