diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2008-10-07 22:55:27 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2008-10-07 22:55:27 +0000 |
commit | 87d3a0cd9006f67fed0d3335d8b1c5ab94a26f8f (patch) | |
tree | 1e3f5000326191e669df486f0a0a471aed765df6 /apps/ca.c | |
parent | 1e369b375eaae43e2ec186f067905a0fab4bd6f1 (diff) |
Experimental new date handling routines. These fix issues with X509_time_adj()
and should avoid any OS date limitations such as the year 2038 bug.
Diffstat (limited to 'apps/ca.c')
-rw-r--r-- | apps/ca.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1399,7 +1399,7 @@ bad: if (!tmptm) goto err; X509_gmtime_adj(tmptm,0); X509_CRL_set_lastUpdate(crl, tmptm); - X509_gmtime_adj(tmptm,(crldays*24+crlhours)*60*60 + crlsec); + X509_time_adj_ex(tmptm, crldays, crlhours*60*60 + crlsec, NULL); X509_CRL_set_nextUpdate(crl, tmptm); ASN1_TIME_free(tmptm); @@ -2006,7 +2006,7 @@ again2: else ASN1_UTCTIME_set_string(X509_get_notBefore(ret),startdate); if (enddate == NULL) - X509_gmtime_adj(X509_get_notAfter(ret),(long)60*60*24*days); + X509_time_adj_ex(X509_get_notAfter(ret),days, 0, NULL); else ASN1_UTCTIME_set_string(X509_get_notAfter(ret),enddate); if (!X509_set_subject_name(ret,subject)) goto err; |