From: Patrick Monnerat Date: Thu, 5 Nov 2015 14:20:43 +0000 (+0100) Subject: curl_ntlm_core: fix 2 curl_off_t constant overflows. X-Git-Tag: curl-7_46_0~107 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f6fbbd6dc3bcc93c681b2f7a14a73fa561b00488;p=thirdparty%2Fcurl.git curl_ntlm_core: fix 2 curl_off_t constant overflows. --- diff --git a/lib/curl_ntlm_core.c b/lib/curl_ntlm_core.c index 38ce805516..db13781a2c 100644 --- a/lib/curl_ntlm_core.c +++ b/lib/curl_ntlm_core.c @@ -676,10 +676,10 @@ CURLcode Curl_ntlm_core_mk_ntlmv2_resp(unsigned char *ntlmv2hash, #ifdef DEBUGBUILD char *force_timestamp = getenv("CURL_FORCETIME"); if(force_timestamp) - tw = (curl_off_t)11644473600 * 10000000; + tw = CURL_OFF_T_C(11644473600) * 10000000; else #endif - tw = ((curl_off_t)time(NULL) + 11644473600) * 10000000; + tw = ((curl_off_t)time(NULL) + CURL_OFF_T_C(11644473600)) * 10000000; /* Calculate the response len */ len = NTLM_HMAC_MD5_LEN + NTLMv2_BLOB_LEN;