diff -r 71c436fe3ce0 -r 4376525cdefb javacommons/security/src/midpauthenticationmoduleimpl.cpp --- a/javacommons/security/src/midpauthenticationmoduleimpl.cpp Wed Jun 09 09:34:07 2010 +0300 +++ b/javacommons/security/src/midpauthenticationmoduleimpl.cpp Mon Jun 21 15:32:50 2010 +0300 @@ -22,6 +22,7 @@ #include "midpauthenticationmoduleimpl.h" #include "storagehandler.h" #include "securityutils.h" +#include "telutils.h" #include "javacertstorehandler.h" #include "securitycommsmessagedefs.h" #include "javastorage.h" @@ -38,7 +39,6 @@ #include #include #include -#include #include using namespace java::security; @@ -455,9 +455,7 @@ break; } - struct timeval tv; - int i = gettimeofday(&tv, NULL); - X509_STORE_CTX_set_time(x509_ctx, X509_V_FLAG_USE_CHECK_TIME, tv.tv_sec); + X509_STORE_CTX_set_time(x509_ctx, X509_V_FLAG_USE_CHECK_TIME, TelUtils::getSecureTime()); // set the callback for validation - needed for the critical extension // used by developer certificates X509_STORE_CTX_set_verify_cb(x509_ctx, verify_callback); @@ -475,7 +473,7 @@ { bool extKeyUsageKnown = false; char EXT_KEY_USAGE_OID[80]; - for (i = 0; i < sk_ASN1_OBJECT_num(extKeyUsage); i++) + for (int i = 0; i < sk_ASN1_OBJECT_num(extKeyUsage); i++) { ASN1_OBJECT *usage = sk_ASN1_OBJECT_value(extKeyUsage,i); OBJ_obj2txt(EXT_KEY_USAGE_OID,