exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

Core Security Technologies Advisory 2010.0415

Core Security Technologies Advisory 2010.0415
Posted Jun 9, 2010
Authored by Core Security Technologies | Site coresecurity.com

Core Security Technologies Advisory - CubeCart PHP Free and Commercial Shopping Cart suffers from a remote SQL injection vulnerability.

tags | exploit, remote, php, sql injection
advisories | CVE-2010-0415
SHA-256 | 94116a9626ca38c007de10d783111163c26361648b8b5ad6d2ed15e85a12245c

Core Security Technologies Advisory 2010.0415

Change Mirror Download
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Core Security Technologies - CoreLabs
Advisory

http://corelabs.coresecurity.com/

SQL Injection in CubeCart PHP Free & Commercial Shopping Cart Application


1. *Advisory Information*

Title: SQL Injection in CubeCart PHP Free & Commercial Shopping Cart
Application
Advisory Id: CORE-2010-0415
Advisory URL:
[http://www.coresecurity.com/content/cubecart-php-shopping-cart-sql-injection]
Date published: 2010-06-08
Date of last update: 2010-06-08
Vendors contacted: CubeCart
Release mode: Coordinated release


2. *Vulnerability Information*

Class: SQL injection [CWE-89]
Impact: Code execution
Remotely Exploitable: Yes
Locally Exploitable: No
CVE Name: CVE-2010-1931
Bugtraq ID: N/A


3. *Vulnerability Description*

There is an SQL Injection[1] vulnerability in the CubeCart PHP
Shopping cart[2], this vulnerability may be exploited by 'HTTP
POST'ing mailicious data to the index.php script of CubeCart. As an
example, exploitation may result in leak of sensitive information or
injection of mailicious code into the shopping cart's web page.


4. *Vulnerable packages*

. CubeCart v.4.3.4
. CubeCart v.4.3.5
. CubeCart v.4.3.6
. CubeCart v.4.3.7
. CubeCart v.4.3.8
. CubeCart v.4.3.9
. Older versions are probably affected too, but they were not checked.


5. *Non-vulnerable packages*

. CubeCart v.4.4.0


6. *Vendor Information, Solutions and Workarounds*

Upgrade to the latest version of CubeCart, available at CubeCart's web
page[1].


7. *Credits*

This vulnerability was discovered and researched by 7Safe
[http://www.7safe.com/]. This advisory was coordinated by Pedro
Varangot
[http://corelabs.coresecurity.com/index.php?module=Wiki&action=view&type=researcher&name=Pedro_Varangot].



8. *Technical Description / Proof of Concept Code*

The shipKey parameter of the following POST request (Updating basket)
is not adequately sanitized resulting in SQL Injection.

/-----
POST /CubeCart/index.php?_g=co&_a=step2 HTTP/1.1
Cookie: [...]
Content-Type: application/x-www-form-urlencoded
[...]

quan%5B3afcdbfeb6ecfbdd0ba628696e3cc163%5D=3&shipKey=1'&coupon=

- -----/

This happens because the 'shipKey' is assumed to be of the 'int'
datatype, and is not cast nor checked before sent to the database, as
we can see in the folling code snippet:

/-----
if(isset($_POST['shipKey']) && $_POST['shipKey']>0) {
$cart->setVar($_POST['shipKey'],'shipKey');
// lose post vars
$refresh = true;
}
- -----/

The following snippet correctly patches this bug:

/-----
if(isset($_POST['shipKey']) && (int)$_POST['shipKey']>0) {
$cart->setVar((int)$_POST['shipKey'],'shipKey');
// lose post vars
$refresh = true;
}
- -----/


9. *Report Timeline*

. 2010-06-02:
Core Security Technologies contacts the CubeCart team informing an SQL
injection vulnerability has been found, and than an advisory draft is
ready.

. 2010-06-02:
The CubeCart team asks Core for a technical description of the
vulnerability, in the form of an advisory draft, over plaintext e-mail.

. 2010-06-02:
Technical details are sent by Core in the form of a draft of this
advisory.

. 2010-06-03:
The CubeCart team replies informing that CubeCart 4.4.0 will be
released very soon, and that this vulnerability will be patched in
that version.

. 2010-06-04:
CubeCart 4.4.0 is released.

. 2010-06-08:
Advisory CORE-2010-0415 is published.


10. *References*

[1] http://www.owasp.org/index.php/SQL_Injection
[http://www.owasp.org/index.php/SQL_Injection]
[2] http://www.cubecart.com/ [http://www.cubecart.com/]


11. *About CoreLabs*

CoreLabs, the research center of Core Security Technologies, is
charged with anticipating the future needs and requirements for
information security technologies. We conduct our research in several
important areas of computer security including system vulnerabilities,
cyber attack planning and simulation, source code auditing, and
cryptography. Our results include problem formalization,
identification of vulnerabilities, novel solutions and prototypes for
new technologies. CoreLabs regularly publishes security advisories,
technical papers, project information and shared software tools for
public use at: [http://corelabs.coresecurity.com/].


12. *About Core Security Technologies*

Core Security Technologies develops strategic solutions that help
security-conscious organizations worldwide develop and maintain a
proactive process for securing their networks. The company's flagship
product, CORE IMPACT, is the most comprehensive product for performing
enterprise security assurance testing. CORE IMPACT evaluates network,
endpoint and end-user vulnerabilities and identifies what resources
are exposed. It enables organizations to determine if current security
investments are detecting and preventing attacks. Core Security
Technologies augments its leading technology solution with world-class
security consulting services, including penetration testing and
software security auditing. Based in Boston, MA and Buenos Aires,
Argentina, Core Security Technologies can be reached at 617-399-6980
or on the Web at [http://www.coresecurity.com].


13. *Disclaimer*

The contents of this advisory are copyright (c) 2010 Core Security
Technologies and (c) 2010 CoreLabs, and may be distributed freely
provided that no fee is charged for this distribution and proper
credit is given.


14. *PGP/GPG Keys*

This advisory has been signed with the GPG key of Core Security
Technologies advisories team, which is available for download at
[http://www.coresecurity.com/files/attachments/core_security_advisories.asc].

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: GnuPT v3.6.3
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkwOjp4ACgkQyNibggitWa1hBQCcDtxBPpLuaYzZ+ACai/qdR0a9
4jMAn3bBbwBMJVVB6YbSfx7fJb/2lOL8
=mQtV
-----END PGP SIGNATURE-----
Login or Register to add favorites

File Archive:

April 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Apr 1st
    10 Files
  • 2
    Apr 2nd
    26 Files
  • 3
    Apr 3rd
    40 Files
  • 4
    Apr 4th
    6 Files
  • 5
    Apr 5th
    26 Files
  • 6
    Apr 6th
    0 Files
  • 7
    Apr 7th
    0 Files
  • 8
    Apr 8th
    22 Files
  • 9
    Apr 9th
    14 Files
  • 10
    Apr 10th
    10 Files
  • 11
    Apr 11th
    13 Files
  • 12
    Apr 12th
    14 Files
  • 13
    Apr 13th
    0 Files
  • 14
    Apr 14th
    0 Files
  • 15
    Apr 15th
    30 Files
  • 16
    Apr 16th
    10 Files
  • 17
    Apr 17th
    22 Files
  • 18
    Apr 18th
    45 Files
  • 19
    Apr 19th
    0 Files
  • 20
    Apr 20th
    0 Files
  • 21
    Apr 21st
    0 Files
  • 22
    Apr 22nd
    0 Files
  • 23
    Apr 23rd
    0 Files
  • 24
    Apr 24th
    0 Files
  • 25
    Apr 25th
    0 Files
  • 26
    Apr 26th
    0 Files
  • 27
    Apr 27th
    0 Files
  • 28
    Apr 28th
    0 Files
  • 29
    Apr 29th
    0 Files
  • 30
    Apr 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close