CVE-2007-0842 (CNNVD-200702-245)
中文标题:
Microsoft Visual C++标准库时间函数拒绝服务漏洞
英文标题:
The 64-bit versions of Microsoft Visual C++ 8.0 standard library (MSVCR80.DLL) time functions, inclu...
漏洞描述
中文描述:
Microsoft Visual C++是基于Windows平台的C++编译器。 Microsoft Visual C++标准库时间函数实现上存在漏洞,攻击者可能利用此漏洞导致相关的应用程序崩溃。 在64位版本的时间函数中,如: localtime() localtime_s() gmtime() gmtime_s() ctime() ctime_s() wctime() wctime_s() fstat() 如果time_t参数大于等于_MAX__TIME64_T(代表3000年1月1日00:00:00)的话,就可能出现异常行为。根据MSDN文档,时间函数必须通过返回空指针或EINVAL指示错误,具体取决于函数类,但不应该调用任何无效的参数处理程序。实际上时间函数调用了无效的类似于assert()的宏,导致所调用的应用程序拒绝服务。 localtime_s函数(loctim64.c)中的示例: /* * Check for illegal __time64_t value */ _VALIDATE_RETURN_ERRCODE_NOEXC( (*ptime >= 0), EINVAL); _VALIDATE_RETURN_ERRCODE( (*ptime <= _MAX__TIME64_T), EINVAL); 最后的字符串初始化了断言,对于负数和超大的值都必须使用无效的VALIDATE_RETURN_ERRCODE_NOEXC。有效代码为: /* * Check for illegal __time64_t value */ _VALIDATE_RETURN_ERRCODE_NOEXC( (*ptime >= 0), EINVAL); _VALIDATE_RETURN_ERRCODE_NOEXC( (*ptime <= _MAX__TIME64_T), EINVAL); 如果使用了任何上述函数的话,使用Microsoft Visual C++ 8.0编译器动态或静态函数库所编译的应用程序都受这个漏洞影响。
英文描述:
The 64-bit versions of Microsoft Visual C++ 8.0 standard library (MSVCR80.DLL) time functions, including (1) localtime, (2) localtime_s, (3) gmtime, (4) gmtime_s, (5) ctime, (6) ctime_s, (7) wctime, (8) wctime_s, and (9) fstat, trigger an assertion error instead of a NULL pointer or EINVAL when processing a time argument later than Jan 1, 3000, which might allow context-dependent attackers to cause a denial of service (application exit) via large time values. NOTE: it could be argued that this is a design limitation of the functions, and the vulnerability lies with any application that does not validate arguments to these functions. However, this behavior is inconsistent with documentation, which does not list assertions as a possible result of an error condition.
CWE类型:
标签:
受影响产品
| 厂商 | 产品 | 版本 | 版本范围 | 平台 | CPE |
|---|---|---|---|---|---|
| microsoft | visual_c\+\+ | 2005 | - | - |
cpe:2.3:a:microsoft:visual_c\+\+:2005:*:*:*:*:*:*:*
|
解决方案
中文解决方案:
英文解决方案:
临时解决方案:
CVSS评分详情
AV:N/AC:L/Au:N/C:N/I:N/A:P
时间信息
利用信息
数据源详情
| 数据源 | 记录ID | 版本 | 提取时间 |
|---|---|---|---|
| CVE | cve_CVE-2007-0842 |
2025-11-11 15:17:49 | 2025-11-11 07:32:41 |
| NVD | nvd_CVE-2007-0842 |
2025-11-11 14:52:09 | 2025-11-11 07:41:27 |
| CNNVD | cnnvd_CNNVD-200702-245 |
2025-11-11 15:08:55 | 2025-11-11 07:49:14 |
版本与语言
安全公告
变更历史
查看详细变更
- vulnerability_type: 未提取 -> 资源管理错误
- cnnvd_id: 未提取 -> CNNVD-200702-245
- data_sources: ['cve', 'nvd'] -> ['cnnvd', 'cve', 'nvd']
查看详细变更
- cvss_score: 未提取 -> 5.0
- cvss_vector: NOT_EXTRACTED -> AV:N/AC:L/Au:N/C:N/I:N/A:P
- cvss_version: NOT_EXTRACTED -> 2.0
- affected_products_count: 0 -> 1
- data_sources: ['cve'] -> ['cve', 'nvd']