GIMP多个整数溢出漏洞
发布日期:2007-07-09
更新日期:2007-07-10
受影响系统:GIMP GIMP 2.2.15
不受影响系统:GIMP GIMP 2.2.16
描述:
BUGTRAQ ID:
24835
CVE(CAN) ID:
CVE-2006-4519
GIMP是GNU Image Manipulation Program(GNU图像处理程序)的缩写,是一款跨平台的图像处理软件。
GIMP所捆绑的多个图形加载器插件中存在整数溢出漏洞,允许攻击者导致GIMP崩溃或以用户权限执行任意指令。
以下行显示的是负责加载DICOM、PNM、PSD、PSP、Sun RAS、XBM和XWD文件格式的代码中漏洞的位置,所有文件都位于plug-ins/common目录中:
dicom.c:391: value = g_new0 (guint8, element_length + 4);
pnm.c:566: data = g_new (guchar, gimp_tile_height () * info->xres * np);
pnm.c:628: data = g_new (guchar, gimp_tile_height () * info->xres * info->np);
pnm.c:681: data = g_new (guchar, gimp_tile_height () * info->xres);
psd.c:2969: PSDheader.rowlength = g_malloc (PSDheader.rows *
psp.c:1225: pixel = g_malloc0 (height * width * bytespp);
sunras.c:955: data = g_malloc (tile_height * width);
sunras.c:1076: data = g_malloc (tile_height * width);
sunras.c:1146: data = g_malloc (tile_height * width * 3);
sunras.c:1231: data = g_malloc (tile_height * width * 3);
xbm.c:879: data = (guchar *) g_malloc (width * tileheight);
xwd.c:1193: data = g_malloc (tile_height * width);
xwd.c:1195: scanline = g_new (guchar, xwdhdr->l_bytes_per_line + 8);
xwd.c:1352: data = g_malloc (tile_height * width);
xwd.c:1441: data = g_malloc (tile_height * width * 3);
xwd.c:1601: data = g_malloc (tile_height * width * 3);
xwd.c:1812: data = g_malloc (tile_height * width * bytes_per_pixel);
在上面的例子中,不可信任来源的整数值用作计算所要分配的长度,由于没有执行整数溢出检查,因此如果用户加载了恶意图形文件的话就可能触发堆溢出。
<*来源:Sean Larsson
链接:
http://developer.gimp.org/NEWS-2.2
http://labs.idefense.com/intelligence/vulnerabilities/display.php?id=551
http://security.gentoo.org/glsa/glsa-200707-09.xml
*>
建议:
临时解决方法:
* 将受影响的加载器模块从GIMP的插件目录移至其他位置。
厂商补丁:
Gentoo
------
Gentoo已经为此发布了一个安全公告(GLSA-200707-09)以及相应补丁:
GLSA-200707-09:GIMP: Multiple integer overflows
链接:
http://security.gentoo.org/glsa/glsa-200707-09.xml
所有GIMP用户都应升级到最新版本:
# emerge --sync
# emerge --ask --oneshot --verbose ">=media-gfx/gimp-2.2.16"
GIMP
----
目前厂商已经发布了升级补丁以修复这个安全问题,请到厂商的主页下载:
http://www.gimp.org/浏览次数:2741
严重程度:0(网友投票)