[openssl-commits] [openssl] OpenSSL_1_0_2-stable update

Dr. Stephen Henson steve at openssl.org
Sun Mar 15 19:48:13 UTC 2015


The branch OpenSSL_1_0_2-stable has been updated
       via  912c8c92b5e703b19a6508de15b229e9fe788656 (commit)
      from  94be83127b08dc3977d2c14304aa61208db048d0 (commit)


- Log -----------------------------------------------------------------
commit 912c8c92b5e703b19a6508de15b229e9fe788656
Author: Carl Jackson <carl at avtok.com>
Date:   Sat Jan 31 02:22:47 2015 -0800

    Fix regression in ASN1_UTCTIME_cmp_time_t
    
    Previously, ASN1_UTCTIME_cmp_time_t would return 1 if s > t, -1 if
    s < t, and 0 if s == t.
    
    This behavior was broken in a refactor [0], resulting in the opposite
    time comparison behavior.
    
    [0]: 904348a4922333106b613754136305db229475ea
    
    PR#3706
    
    Reviewed-by: Stephen Henson <steve at openssl.org>
    Reviewed-by: Rich Salz <rsalz at openssl.org>
    (cherry picked from commit da27006df06853a33b132133699a7aa9d4277920)

-----------------------------------------------------------------------

Summary of changes:
 crypto/asn1/a_utctm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/crypto/asn1/a_utctm.c b/crypto/asn1/a_utctm.c
index 0578c88..724a10b 100644
--- a/crypto/asn1/a_utctm.c
+++ b/crypto/asn1/a_utctm.c
@@ -297,7 +297,7 @@ int ASN1_UTCTIME_cmp_time_t(const ASN1_UTCTIME *s, time_t t)
     if (!OPENSSL_gmtime(&t, &ttm))
         return -2;
 
-    if (!OPENSSL_gmtime_diff(&day, &sec, &stm, &ttm))
+    if (!OPENSSL_gmtime_diff(&day, &sec, &ttm, &stm))
         return -2;
 
     if (day > 0)


More information about the openssl-commits mailing list