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

GLPI 0.80.61 Local File Inclusion / Remote File Inclusion

GLPI 0.80.61 Local File Inclusion / Remote File Inclusion
Posted Feb 11, 2012
Authored by Emilien Girault

GLPI versions 0.80.61 and below suffer from local file inclusion and remote file inclusion vulnerabilities.

tags | exploit, remote, local, vulnerability, code execution, file inclusion
advisories | CVE-2012-1037
SHA-256 | 0f618b4a22f1c38efc5bf06ca069a4fa57200e710e5d7a97fd5eca84a84d382f

GLPI 0.80.61 Local File Inclusion / Remote File Inclusion

Change Mirror Download
CVE-2012-1037: GLPI <= 0.80.61 LFI/RFI

Severity: Important

Vendor: GLPI - http://www.glpi-project.org

Versions Affected
=================

All versions between 0.78 and 0.80.61

Description
===========

GLPI fails to properly sanitize the GET 'sub_type' parameter in the front/popup.php file:

[...]
checkLoginUser();

if (isset($_GET["popup"])) {
$_SESSION["glpipopup"]["name"] = $_GET["popup"];
}

if (isset($_SESSION["glpipopup"]["name"])) {
switch ($_SESSION["glpipopup"]["name"]) {
[...]
case "add_ruleparameter" :
popHeader($LANG['ldap'][35], $_SERVER['PHP_SELF']);
include strtolower($_GET['sub_type']."Parameter.php"); // <=======
break;
[...]

To be triggered, the attacker needs to be authenticated. However, GLPI provides default accounts that often aren't changed or disabled:

glpi/glpi
tech/tech
normal/normal
post-only/postonly

Impact
======

Since there is a suffix, the vulnerability can be used as a RFI (requires allow_url_include = On).

For LFI, the target file has to end up with "parameter.php". GLPI automatically escapes all GET and POST parameters with addslashes(), so the null byte technique is not usable. I have not tested exploitation using path truncation technique but it might be possible.


Mitigation
==========

Upgrade to GLPI 0.80.7.


Exploit
=======

http://<server>/front/popup.php?popup=add_ruleparameter&sub_type=<file>


Timeline
========

08 feb 2012 - Found the bug.
09 feb 2012 - Contacted the GLPI Team.
09 feb 2012 - Bug fixed & new version available.

Thanks to the GLPI team for being responsive!

References
==========

http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2012-1037
https://forge.indepnet.net/projects/glpi/versions/685
https://forge.indepnet.net/projects/glpi/repository/revisions/17457/diff/branches/0.80-bugfixes/front/popup.php


--
Emilien Girault
Login or Register to add favorites

File Archive:

July 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Jul 1st
    27 Files
  • 2
    Jul 2nd
    10 Files
  • 3
    Jul 3rd
    35 Files
  • 4
    Jul 4th
    27 Files
  • 5
    Jul 5th
    18 Files
  • 6
    Jul 6th
    0 Files
  • 7
    Jul 7th
    0 Files
  • 8
    Jul 8th
    28 Files
  • 9
    Jul 9th
    44 Files
  • 10
    Jul 10th
    24 Files
  • 11
    Jul 11th
    25 Files
  • 12
    Jul 12th
    11 Files
  • 13
    Jul 13th
    0 Files
  • 14
    Jul 14th
    0 Files
  • 15
    Jul 15th
    28 Files
  • 16
    Jul 16th
    6 Files
  • 17
    Jul 17th
    0 Files
  • 18
    Jul 18th
    0 Files
  • 19
    Jul 19th
    0 Files
  • 20
    Jul 20th
    0 Files
  • 21
    Jul 21st
    0 Files
  • 22
    Jul 22nd
    0 Files
  • 23
    Jul 23rd
    0 Files
  • 24
    Jul 24th
    0 Files
  • 25
    Jul 25th
    0 Files
  • 26
    Jul 26th
    0 Files
  • 27
    Jul 27th
    0 Files
  • 28
    Jul 28th
    0 Files
  • 29
    Jul 29th
    0 Files
  • 30
    Jul 30th
    0 Files
  • 31
    Jul 31st
    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