Skip to content

eBPF-based security platform

crypto: do not check certificate dates when verifying a signature

Daniel Borkmann882d136eb513
diff --git a/util/crypto_openssl.c b/util/crypto_openssl.c
index be83f767..5585b40e 100644
--- a/util/crypto_openssl.c
+++ b/util/crypto_openssl.c
@@ -270,7 +270,8 @@ int shirudo_verify_detached(const uint8_t *payload, size_t payload_len,
out = BIO_new(BIO_s_null());
store = X509_STORE_new();
if (!sig || !data || !out || !store ||
- X509_STORE_add_cert(store, cert->impl) != 1)
+ X509_STORE_add_cert(store, cert->impl) != 1 ||
+ X509_STORE_set_flags(store, X509_V_FLAG_NO_CHECK_TIME) != 1)
goto done;
signers = sk_X509_new_null();
if (!signers || !sk_X509_push(signers, cert->impl))