]> granicus.if.org Git - libevent/commitdiff
OpenSSL 3 fixes: use SHA256 instead of SHA1
authorPeter Edwards <peadar@arista.com>
Mon, 27 Jun 2022 21:00:05 +0000 (22:00 +0100)
committerPeter Edwards <peadar@arista.com>
Mon, 27 Jun 2022 22:07:58 +0000 (23:07 +0100)
OpenSSL 3.x does not support signing certificates with SHA1 by default.
Use SHA256 instead.

test/regress_openssl.c

index 1bf0b50dd842494f83d5c6a5dc1d02d6ed2db599..f74cae1ce6a8c3305f3cfe7cea7ac5ca59529211 100644 (file)
@@ -103,7 +103,7 @@ ssl_getcert(EVP_PKEY *key)
        now += 3600;
        X509_time_adj(X509_getm_notAfter(x509), 0, &now);
        X509_set_pubkey(x509, key);
-       tt_assert(0 != X509_sign(x509, key, EVP_sha1()));
+       tt_assert(0 != X509_sign(x509, key, EVP_sha256()));
 
        return x509;
 end: