发布时间 :2005-02-14 00:00:00
修订时间 :2008-09-10 15:35:31

[原文]CitrusDB 0.3.6 and earlier does not verify authorization for the (1) importcc.php and (2) uploadcc.php, which allows remote attackers to upload credit card data and obtain sensitive information such as the pathnames for temporary files that store credit card data, and facilitates the exploitation of other vulnerabilities.

[CNNVD]CitrusDB CSV文件上传访问验证漏洞(CNNVD-200502-054)

        CitrusDB 是一个基于Web的客户关系维护和账单管理解决方案。
        CitrusDB 0.3.6及更早版本不验证(1) importcc.php和(2) uploadcc.php的授权,这可让远程攻击者上传信用卡数据并获得敏感信息(例如存储信用卡数据的临时文件的路径名),并进一步非法利用其他漏洞。

- CVSS (基础分值)

CVSS分值: 6.4 [中等(MEDIUM)]
机密性影响: PARTIAL [很可能造成信息泄露]
完整性影响: PARTIAL [可能会导致系统文件被修改]
可用性影响: NONE [对系统可用性无影响]
攻击复杂度: LOW [漏洞利用没有访问限制 ]
攻击向量: [--]
身份认证: NONE [漏洞利用无需身份认证]

- CPE (受影响的平台与产品)


- OVAL (用于检测的技术细节)


- 官方数据库链接
(官方数据源) MITRE
(官方数据源) NVD
(官方数据源) CNNVD

- 其它链接及资源
(UNKNOWN)  FULLDISC  20050214 Advisory: Upload Authorization bypass in CitrusDB

- 漏洞信息

CitrusDB CSV文件上传访问验证漏洞
中危 访问验证错误
2005-02-14 00:00:00 2006-05-12 00:00:00
        CitrusDB 是一个基于Web的客户关系维护和账单管理解决方案。
        CitrusDB 0.3.6及更早版本不验证(1) importcc.php和(2) uploadcc.php的授权,这可让远程攻击者上传信用卡数据并获得敏感信息(例如存储信用卡数据的临时文件的路径名),并进一步非法利用其他漏洞。

- 公告与补丁


- 漏洞信息 (F36182)

rt-sa-2005-003.txt (PacketStormID:F36182)
2005-02-25 00:00:00
advisory,vulnerability,sql injection

CitrusDB suffers from SQL injection vulnerabilities in version 0.3.6.

Advisory: Upload Authorization bypass in CitrusDB

A group of students at our lab called RedTeam found an authorization  
bypass vulnerability in CitrusDB which results
in upload of fake credit card data, SQL-Injection and disclosure of  
credit card data.


Product: CitrusDB
Affected Version: 0.3.6 (verified), probably <=0.3.6
Immune Version: none (2005-01-30)
OS affected: all
Security-Risk: high
Remote-Exploit: yes
Vendor-Status: informed
Advisory-Status: public
CVE: CAN-2005-0409


Description from vendor:
"CitrusDB is an open source customer database application that uses PHP  
and a
database backend (currently MySQL) to keep track of customer  
services, products, billing, and customer service information."

In the credit card data upload/import scripts it is only checked  
whether or
not a user is logged in but no privilege check is done.

More Details

In ./citrusdb/tools/importcc.php and ./citrusdb/tools/uploadcc.php no
authorization is done. Any logged in user (or in combination with
CAN-2005-0408 anybody) may upload a cvs file containing credit card  
data. He
also gets knowledge of the path to the temporary file that stores the
uploaded credit card data and may fetch additional uploaded credit card  
(compare CAN-2005-0229) if the file is accessible via http.  
Additionally he
may perform an SQL-Injection (compare CAN-2005-0410).

Proof of Concept

This uploads the file exploit.cvs.

curl -D - --cookie "id_hash=2378c7b70e77d9c6737d697a46cbe34b;
user_name=testor" http://<target>/citrusdb/tools/uploadcc.php --form
userfile=@exploit.cvs --form Import=Import

Note: The cookie has to be adjusted to an existing user.

This imports the file to the credit card database:

curl -D - --cookie "id_hash=2378c7b70e77d9c6737d697a46cbe34b;

Note: The cookie has to be adjusted to an existing user.
No data will be imported if the cvs file is empty, the administrator  
wouldn't notice that the temporary file is now empty but the attacker  
the path to the temporary file and may access data that is uploaded in  
future if the path is inside document root (see CAN-2005-0229).
An SQL-Injection is also possible (see CAN-2005-0410)


Disable the upload of cvs data, e.g. by setting the path for the  
cvs file ($path_to_ccfile) to a non-writeable directory.



Security Risk

The security risk is high because an attacker may corrupt important  
card) data and an attack is very easy to perform.


2005-02-04 Email sent to author
2005-02-12 CVE number requested
2005-02-14 posted as CAN-2005-0409

RedTeam is a penetration testing group working at the Laboratory for
Dependable Distributed Systems at RWTH-Aachen University. You can find  
Information on the RedTeam Project at

Laboratory for Dependable Distributed Systems, RWTH Aachen University
Get news of the lab at    

- 漏洞信息

CitrusDB importcc.php Arbitrary Database Injection
Remote / Network Access

- 漏洞描述

Unknown or Incomplete

- 时间线

2005-02-13 Unknow
2005-02-13 Unknow

- 解决方案

Unknown or Incomplete

- 相关参考

- 漏洞作者

Unknown or Incomplete

- 漏洞信息

CitrusDB CSV File Upload Access Validation Vulnerability
Access Validation Error 12557
Yes No
2005-02-15 12:00:00 2009-07-12 10:06:00
Discovery of this vulnerability is credited to RedTeam.

- 受影响的程序版本

CitrusDB Customer Database 0.3.6

- 漏洞讨论

CitrusDB is reportedly affected by an access validation vulnerability during the upload of CSV files. Exploitation of this issue could result in path disclosure or SQL injection. The issue exists because the application fails to verify user credentials during file upload and import.

These issues are reported to affect CitrusDB 0.3.6; earlier versions may also be affected.

- 漏洞利用

No exploit is required.

The following proof of concept is available:
This uploads the file exploit.csv.

curl -D - --cookie "id_hash=2378c7b70e77d9c6737d697a46cbe34b;
user_name=testor" http://&lt;target&gt;/citrusdb/tools/uploadcc.php --form
userfile=@exploit.csv --form Import=Import

This imports the file to the credit card database:

curl -D - --cookie "id_hash=2378c7b70e77d9c6737d697a46cbe34b;

Note: The above proof of concepts require the id_hash of an existing user.

THe following proof of concept demonstrates the SQL injection vulnerability:
Reportedly supplying ',,,,, as the contents of the uploaded csv file will make the SQL query in './citrusdb/tools/importcc.php' fail.

- 解决方案

Currently we are not aware of any vendor-supplied patches for this issue. If you feel we are in error or are aware of more recent information, please mail us at: <>.

- 相关参考