Skip to content

Commit

Permalink
Added some comments
Browse files Browse the repository at this point in the history
  • Loading branch information
jstedfast committed Jul 25, 2021
1 parent 413edf9 commit 504d399
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions MailKit/MailService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -496,6 +496,7 @@ static bool IsUntrustedRoot (X509Chain chain)
return true;
}

// Note: This is used by SslHandshakeException to build the exception message.
internal SslCertificateValidationInfo SslCertificateValidationInfo;

/// <summary>
Expand Down Expand Up @@ -531,6 +532,7 @@ protected bool DefaultServerCertificateValidationCallback (object sender, X509Ce
}
}

// Note: The SslHandshakeException.Create() method will nullify this once it's done using it.
SslCertificateValidationInfo = new SslCertificateValidationInfo (sender, certificate, chain, sslPolicyErrors);

return false;
Expand Down

0 comments on commit 504d399

Please sign in to comment.