diff options
author | Joel Sing <jsing@cvs.openbsd.org> | 2015-10-05 06:13:59 +0000 |
---|---|---|
committer | Joel Sing <jsing@cvs.openbsd.org> | 2015-10-05 06:13:59 +0000 |
commit | 0dac84f72104947be395f09f488d60dbb4b332a0 (patch) | |
tree | 9676092244a25b95a2b2b1f2789e79899e57b16d /lib/libssl | |
parent | 94fccd20e11bdef3eefba84395ec39a37c07008f (diff) |
Make sure dot is not set after tz - fixes incorrect handling, which allows
20151005171301+1.09Z to be treated as a valid time.
ok beck@
Diffstat (limited to 'lib/libssl')
-rw-r--r-- | lib/libssl/src/crypto/asn1/a_time_tm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libssl/src/crypto/asn1/a_time_tm.c b/lib/libssl/src/crypto/asn1/a_time_tm.c index 7b25e439c4c..81a92ad6d80 100644 --- a/lib/libssl/src/crypto/asn1/a_time_tm.c +++ b/lib/libssl/src/crypto/asn1/a_time_tm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_time_tm.c,v 1.2 2015/10/04 15:15:11 jsing Exp $ */ +/* $OpenBSD: a_time_tm.c,v 1.3 2015/10/05 06:13:58 jsing Exp $ */ /* * Copyright (c) 2015 Bob Beck <beck@openbsd.org> * @@ -120,7 +120,7 @@ asn1_time_parse(const char *bytes, size_t len, struct tm *tm, int mode) char *t = buf + i; if (isdigit((unsigned char)*t)) continue; - if (*t == '.' && dot == NULL) { + if (*t == '.' && dot == NULL && tz == NULL) { dot = t; continue; } |