CVE-2007-2054 (CNNVD-200704-585)

HIGH
中文标题:
AFFLIB多个格式串处理漏洞
英文标题:
Multiple format string vulnerabilities in AFFLIB before 2.2.6 allow remote attackers to execute arbi...
CVSS分数: 7.5
发布时间: 2007-04-30 22:00:00
漏洞类型: 授权问题
状态: PUBLISHED
数据质量分数: 0.30
数据版本: v3
漏洞描述
中文描述:

AFFLIB是用于操作高级取证格式(AFF)文件的开源函数库。 AFFLIB的一些命令行工具实现上存在格式串处理漏洞,本地攻击者可能利用此漏洞提升自己的权限。 这些工具以格式串参数向warn()和err()调用传输一些命令行参数。如果攻击者能够影响这些命令行参数的话,就可能导致执行任意指令。 * s3格式串注入 * 文件:lib/s3.cpp 行数:207 err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响名称的话就可以导致格式串注入漏洞。192-207行说明了这个问题: void s3_cp(const char *fname,string key) { struct s3headers meta[2] = {{0,0},{0,0}}; char buf[64]; if(opt_flag){ snprintf(buf,sizeof(buf),"%d",opt_flag); meta[0].name = AMAZON_METADATA_PREFIX "arg"; meta[0].value = buf; } /* Read from fname into a buffer. * Note that we do this with read, so that we can read from stdin */ FILE *f = fopen(fname,"r"); if(!f) err(1,fname); 如果s3二进制程序为setuid/setgid,或s3程序在CGI脚本中执行的话,攻击者就可以利用这个漏洞。 * afconvert格式串注入 * 文件:tools/afconvert.cpp 行数:226、263和305 3个err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响名称的话就可以导致格式串注入漏洞。 * afcopy格式串注入 * 文件:tools/afcopy.cpp 行数:202和250 2个err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响名称的话就可以导致格式串注入漏洞。 * afinfo格式串注入 * 文件:tools/afinfo.cpp 行数:584 err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响名称的话就可以导致格式串注入漏洞。* aimage格式串注入 * 文件:aimage/aimage.cpp 行数:577 err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响名称的话就可以导致格式串注入漏洞。548-577行说明了这个问题: int getlock(class imager *im) { /* If the file exists and the PID in the file is running, * can't get the lock. */ char lockfile[MAXPATHLEN]; sprintf(lockfile,"/tmp/aimge.%s.lock",im->infile); if(access(lockfile,F_OK)==0){ /* Lockfile exists. Get it's pid */ char buf[1024]; FILE *f = fopen(lockfile,"r"); if(!f){ perror(lockfile); // can't read lockfile... return -1; } fgets(buf,sizeof(buf),f); buf[sizeof(buf)-1] = 0; int pid = atoi(buf); if(checkpid(pid)==0){ /* PID is not running; we can delete the lockfile */ if(unlink(lockfile)){ err(1,"could not delete lockfile %s: ",lockfile); } } /* PID is running; generate error */ errx(1,"%s is locked by process %d\n",im->infile,pid); } FILE *f = fopen(lockfile,"w"); if(!f){ err(1,lockfile); 由于用户可以指定im->infile值,因此lockfile字符串可能包含有格式串字符。如果aimage二进制程序为setuid/setgid或aimage程序在CGI脚本中执行的话,就可能导致这个漏洞。 * imager格式串注入 * 文件:aimage/imager.cpp 行数:265 err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响名称的话就可以导致格式串注入漏洞。 * afxml格式串注入 * 文件:tools/afxml.cpp 行数:101 err()调用中的一个命令行参数用作了格式串,如果攻击者能够影响户名称的话就可以导致格式串注入漏洞。

英文描述:

Multiple format string vulnerabilities in AFFLIB before 2.2.6 allow remote attackers to execute arbitrary code via certain command line parameters, which are used in (1) warn and (2) err calls in (a) lib/s3.cpp, (b) tools/afconvert.cpp, (c) tools/afcopy.cpp, (d) tools/afinfo.cpp, (e) aimage/aimage.cpp, (f) aimage/imager.cpp, and (g) tools/afxml.cpp. NOTE: the aimage.cpp vector (e) has since been recalled from the researcher's original advisory, since the code is not called in any version of AFFLIB.

CWE类型:
(暂无数据)
标签:
(暂无数据)
受影响产品
厂商 产品 版本 版本范围 平台 CPE
afflib afflib * - - cpe:2.3:a:afflib:afflib:*:*:*:*:*:*:*:*
解决方案
中文解决方案:
(暂无数据)
英文解决方案:
(暂无数据)
临时解决方案:
(暂无数据)
参考链接
2657 third-party-advisory
cve.org
访问
afflib-multiple-format-string(33969) vdb-entry
cve.org
访问
20070427 AFFLIB(TM): Multiple Format String Injections mailing-list
cve.org
访问
无标题 x_refsource_MISC
cve.org
访问
CVSS评分详情
7.5
HIGH
CVSS向量: AV:N/AC:L/Au:N/C:P/I:P/A:P
CVSS版本: 2.0
机密性
PARTIAL
完整性
PARTIAL
可用性
PARTIAL
时间信息
发布时间:
2007-04-30 22:00:00
修改时间:
2024-08-07 13:23:49
创建时间:
2025-11-11 15:32:43
更新时间:
2025-11-11 15:49:17
利用信息
暂无可利用代码信息
数据源详情
数据源 记录ID 版本 提取时间
CVE cve_CVE-2007-2054 2025-11-11 15:17:51 2025-11-11 07:32:43
NVD nvd_CVE-2007-2054 2025-11-11 14:52:10 2025-11-11 07:41:29
CNNVD cnnvd_CNNVD-200704-585 2025-11-11 15:08:56 2025-11-11 07:49:17
版本与语言
当前版本: v3
主要语言: EN
支持语言:
EN ZH
安全公告
暂无安全公告信息
变更历史
v3 CNNVD
2025-11-11 15:49:17
vulnerability_type: 未提取 → 授权问题; cnnvd_id: 未提取 → CNNVD-200704-585; data_sources: ['cve', 'nvd'] → ['cnnvd', 'cve', 'nvd']
查看详细变更
  • vulnerability_type: 未提取 -> 授权问题
  • cnnvd_id: 未提取 -> CNNVD-200704-585
  • data_sources: ['cve', 'nvd'] -> ['cnnvd', 'cve', 'nvd']
v2 NVD
2025-11-11 15:41:29
severity: SeverityLevel.MEDIUM → SeverityLevel.HIGH; cvss_score: 未提取 → 7.5; cvss_vector: NOT_EXTRACTED → AV:N/AC:L/Au:N/C:P/I:P/A:P; cvss_version: NOT_EXTRACTED → 2.0; affected_products_count: 0 → 1; data_sources: ['cve'] → ['cve', 'nvd']
查看详细变更
  • severity: SeverityLevel.MEDIUM -> SeverityLevel.HIGH
  • cvss_score: 未提取 -> 7.5
  • cvss_vector: NOT_EXTRACTED -> AV:N/AC:L/Au:N/C:P/I:P/A:P
  • cvss_version: NOT_EXTRACTED -> 2.0
  • affected_products_count: 0 -> 1
  • data_sources: ['cve'] -> ['cve', 'nvd']