diff options
Diffstat (limited to 'src/lib/libtls/tls_ocsp.c')
| -rw-r--r-- | src/lib/libtls/tls_ocsp.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/libtls/tls_ocsp.c b/src/lib/libtls/tls_ocsp.c index c7eb3e5986..f7d7ba9199 100644 --- a/src/lib/libtls/tls_ocsp.c +++ b/src/lib/libtls/tls_ocsp.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: tls_ocsp.c,v 1.24 2023/11/13 10:56:19 tb Exp $ */ | 1 | /* $OpenBSD: tls_ocsp.c,v 1.25 2024/03/24 11:30:12 beck Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2015 Marko Kreen <markokr@gmail.com> | 3 | * Copyright (c) 2015 Marko Kreen <markokr@gmail.com> |
| 4 | * Copyright (c) 2016 Bob Beck <beck@openbsd.org> | 4 | * Copyright (c) 2016 Bob Beck <beck@openbsd.org> |
| @@ -25,6 +25,7 @@ | |||
| 25 | 25 | ||
| 26 | #include <openssl/err.h> | 26 | #include <openssl/err.h> |
| 27 | #include <openssl/ocsp.h> | 27 | #include <openssl/ocsp.h> |
| 28 | #include <openssl/posix_time.h> | ||
| 28 | #include <openssl/x509.h> | 29 | #include <openssl/x509.h> |
| 29 | 30 | ||
| 30 | #include <tls.h> | 31 | #include <tls.h> |
| @@ -68,7 +69,7 @@ tls_ocsp_asn1_parse_time(struct tls *ctx, ASN1_GENERALIZEDTIME *gt, time_t *gt_t | |||
| 68 | return -1; | 69 | return -1; |
| 69 | if (!ASN1_TIME_to_tm(gt, &tm)) | 70 | if (!ASN1_TIME_to_tm(gt, &tm)) |
| 70 | return -1; | 71 | return -1; |
| 71 | if ((*gt_time = timegm(&tm)) == -1) | 72 | if (!OPENSSL_timegm(&tm, gt_time)) |
| 72 | return -1; | 73 | return -1; |
| 73 | return 0; | 74 | return 0; |
| 74 | } | 75 | } |
