/// <summary> /// Creates a certificate resolver that retrieves certificates from the given certificate index instance. /// </summary> /// <param name="index"> /// An index instance providing <see cref="IX509CertificateIndex"/> /// </param> /// <param name="cacheSettings"> /// The cache settings to use. Specify null for no caching. /// </param> public CertificateResolver(IX509CertificateIndex index, CacheSettings cacheSettings) { if (index == null) { throw new ArgumentNullException("index"); } m_certIndex = index; if (cacheSettings != null && cacheSettings.Cache) { m_certificateCache = new CertificateCache(cacheSettings); } }