mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
genprotimg/crypto: use X509_get0_not(After|Before)
Use X509_get0_not(After|Before) since X509_get_notBefore() and X509_get_notAfter() were deprecated in OpenSSL 1.1.0 (see https://www.openssl.org/docs/man1.1.0/man3/X509_set1_notBefore.html). Github-ID: https://github.com/ibm-s390-linux/s390-tools/issues/112 Reviewed-by: Patrick Steuer <patrick.steuer@de.ibm.com> Signed-off-by: Marc Hartmayer <mhartmay@linux.ibm.com> Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
This commit is contained in:
committed by
Jan Höppner
parent
d90344a2d5
commit
c5d566a4da
@@ -1655,8 +1655,8 @@ gint verify_host_key(X509 *host_key, GSList *issuer_pairs,
|
||||
}
|
||||
|
||||
if (!(verify_flags & X509_V_FLAG_NO_CHECK_TIME)) {
|
||||
const ASN1_TIME *last = X509_get_notBefore(host_key);
|
||||
const ASN1_TIME *next = X509_get_notAfter(host_key);
|
||||
const ASN1_TIME *last = X509_get0_notBefore(host_key);
|
||||
const ASN1_TIME *next = X509_get0_notAfter(host_key);
|
||||
|
||||
if (!last || !next || check_validity_period(last, next)) {
|
||||
g_set_error(err, PV_CRYPTO_ERROR,
|
||||
|
||||
Reference in New Issue
Block a user