diff --git a/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/ChainPal.OpenSsl.cs b/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/ChainPal.OpenSsl.cs index 72a691f0811f58e902117095f75fd40cdfff00fd..26489a24f8feaafd173cd5a1cc2bbd2d140ae54f 100644 --- a/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/ChainPal.OpenSsl.cs +++ b/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/ChainPal.OpenSsl.cs @@ -164,7 +164,12 @@ public static void FlushStores() { if (OpenSslX509ChainProcessor.IsCompleteChain(status)) { - if (status != Interop.Crypto.X509VerifyStatusCode.X509_V_OK) + // Checking the validity period for the certificates in the chain is done after the + // check for a trusted root, so accept expired (or not yet valid) as acceptable for + // processing revocation. + if (status != Interop.Crypto.X509VerifyStatusCode.X509_V_OK && + status != Interop.Crypto.X509VerifyStatusCodeUniversal.X509_V_ERR_CERT_NOT_YET_VALID && + status != Interop.Crypto.X509VerifyStatusCodeUniversal.X509_V_ERR_CERT_HAS_EXPIRED) { if (OpenSslX509ChainEventSource.Log.IsEnabled()) {