forked from aniani/gmnisrv
1
0
Fork 0

Fix integer overflow error in tls.c

This commit is contained in:
bacardi55 2021-03-23 20:04:20 +01:00 committed by Drew DeVault
parent f23ec10a6d
commit 8b65e303b0
1 changed files with 1 additions and 1 deletions

View File

@ -44,7 +44,7 @@ tls_host_gencert(struct gmnisrv_tls *tlsconf, struct gmnisrv_host *host,
X509_set_version(x509, 2);
ASN1_INTEGER_set(X509_get_serialNumber(x509), 1);
X509_gmtime_adj(X509_get_notBefore(x509), 0);
X509_gmtime_adj(X509_get_notAfter(x509), 31536000L * 200); // 200 years
X509_gmtime_adj(X509_get_notAfter(x509), LONG_MAX);
X509_set_pubkey(x509, pkey);
char *organization = "gmnisrv";