This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Threading; | |
using System.Collections.Generic; | |
using System.Net.Security; | |
using System.Net.Sockets; | |
using System.Security.Authentication; | |
using System.Security.Cryptography.X509Certificates; | |
using System.Threading.Tasks; | |
namespace ssltest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Original version by Stephen Toub and Shawn Farkas. | |
* Random pool and thread safety added by Markus Olsson (freakcode.com). | |
* | |
* Original source: http://msdn.microsoft.com/en-us/magazine/cc163367.aspx | |
* | |
* Some benchmarks (2009-03-18): | |
* | |
* Results produced by calling Next() 1 000 000 times on my machine (dual core 3Ghz) | |
* |