Skip to content

Instantly share code, notes, and snippets.

@svrooij
Last active January 2, 2016 07:19
Show Gist options
  • Save svrooij/8269109 to your computer and use it in GitHub Desktop.
Save svrooij/8269109 to your computer and use it in GitHub Desktop.
Security failure for mobile apps!This is a sample found on the internet, and this is way their are a lot of mobile apps that are broken. You can easily make it talk to an other server....
ServicePointManager.ServerCertificateValidationCallback = (sender, certificate, chain, sslPolicyErrors) => {
Console.WriteLine("Certificaat: {0}",certificate.Subject);
Console.WriteLine("SslPolicy: {0}",sslPolicyErrors);
return true; //This row is the problem. If you don't know why, I wouldn't use apps from your company!
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment