Skip to content

Commit 3b2c9dd

Browse files
arelleguedauinsight
authored andcommitted
Fix | Suppress CodeQL X509RevocationMode warning. (dotnet#2432)
1 parent 43519b7 commit 3b2c9dd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/VirtualSecureModeEnclaveProviderBase.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,10 @@ private bool VerifyHealthReportAgainstRootCertificate(X509Certificate2Collection
243243
chain.ChainPolicy.ExtraStore.Add(cert);
244244
}
245245

246+
// An Always Encrypted-enabled driver doesn't verify an expiration date or a certificate authority chain.
247+
// A certificate is simply used as a key pair consisting of a public and private key. This is by design.
248+
249+
// CodeQL [SM00395] By design. Always Encrypted certificates should not be checked.
246250
chain.ChainPolicy.RevocationMode = X509RevocationMode.NoCheck;
247251

248252
if (!chain.Build(healthReportCert))

0 commit comments

Comments
 (0)