Ethical Hacking Learn to find vulnerabilities before the bad guys do! Gain real world hands on hacking experience in our state of the art hacking lab. Course designed and taught by expert instructors with years of penetration testing experience. 12 student maximum in every class. Certification attempt included in every package. | Computer Forensics Training at InfoSec Institute Gain the in-demand skills of a certified computer examiner, learn to recover trace data left behind by fraud, theft, and cybercrime perpetrators. Discover the source of computer crime and abuse at your organization so that it never happens again. All of our class sizes are guaranteed to be 12 students or less to facilitate one-on-one interaction with one of our expert instructors. |

| Subject: | [UNIX] TYPO3 Web Content Manager File System Path Disclosure |
|---|---|
| Date: | 25 Jan 2006 09:46:19 +0200 |
The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com - - promotion The SecuriTeam alerts list - Free, Accurate, Independent. Get your security news from a reliable source. http://www.securiteam.com/mailinglist.html - - - - - - - - - TYPO3 Web Content Manager File System Path Disclosure ------------------------------------------------------------------------ SUMMARY TYPO3 is "a free Open Source content management system for enterprise purposes on the web and in Intranets. It offers full flexibility and extendability while featuring an accomplished set of ready-made interfaces, functions and modules". The vulnerability discovered in TYPO3, allows remote users to disclose the file system path of the application when requesting certain files. DETAILS Vulnerable Systems: * TYPO3 version 3.7.1 The following files were found to disclose the application path: http://hostname/typo3/t3lib/thumbs.php http://hostname/tslib/showpic.php http://hostname/t3lib/stddb/tables.php The issue is due to the application failing to properly determine its own physical path and therefore trying to 'require()' a wrong class file. Vulnerable code:
From init.php, line 71:
define('PATH_thisScript',str_replace('//','/', str_replace('\\','/',
(php_sapi_name()=='cgi'||php_sapi_name()=='isapi'
||php_sapi_name()=='cgi-fcgi') && ($_SERVER['ORIG_PATH_TRANSLATED']?
$_SERVER['ORIG_PATH_TRANSLATED']:$_SERVER['PATH_TRANSLATED']) ?
($_SERVER['ORIG_PATH_TRANSLATED']?
$_SERVER['ORIG_PATH_TRANSLATED']:$_SERVER['PATH_TRANSLATED']) :
($_SERVER['ORIG_SCRIPT_FILENAME']?$_SERVER['ORIG_SCRIPT_FILENAME'] :
$_SERVER['SCRIPT_FILENAME']))));
From the PHP manual:
"You can define a constant by using the define()-function. Once a
constants defined, it can never be changed or undefined"
The vulnerable files listed above fail to include init.php and the
'PATH_thisScript' variable is locally calculated:
define('PATH_thisScript',str_replace('//','/', str_replace('\\','/',
(php_sapi_name()=='cgi'||php_sapi_name()=='isapi'
||php_sapi_name()=='cgi-fcgi')&&($_SERVER['ORIG_PATH_TRANSLATED']?$_SERVER['
ORIG_PATH_TRANSLATED']:$_SERVER['PATH_TRANSLATED'])?
($_SERVER['ORIG_PATH_TRANSLATED']?$_SERVER['ORIG_PATH_TRANSLATED']:$_SERVER[
'PATH_TRANSLATED']):($_SERVER['ORIG_SCRIPT_FILENAME']?$_SERVER['ORIG_SCRIPT_
FILENAME']:$_SERVER['SCRIPT_FILENAME']))));
define('PATH_site', ereg_replace('[^/]*.[^/]*$','',PATH_thisScript));
define('PATH_t3lib', PATH_site.'t3lib/'); define('PATH_tslib',
PATH_site.'tslib/');
At this point, constants 'PATH_t3lib' and 'PATH_tslib' contain wrong
values and any 'require()' function using these constants will not work
and will disclose the file system path.
Disclosure Timeline:
Contact was initially made via the TYPO3 bug reporting system on January
13th 2006.
Patch Availability:
On January 14th a patch for the issue was published on the site (
<http://bugs.typo3.org/view.php?id=2248>
http://bugs.typo3.org/view.php?id=2248)
ADDITIONAL INFORMATION
The information has been provided by Rodrigo Marcos.
The original article can be found at:
<http://www.irmplc.com/advisories.htm>
http://www.irmplc.com/advisories.htm
========================================
This bulletin is sent to members of the SecuriTeam mailing list.
To unsubscribe from the list, send mail with an empty subject line and body to:
list-unsubscribe@securiteam.com
In order to subscribe to the mailing list, simply forward this email to:
list-subscribe@securiteam.com
====================
====================
DISCLAIMER:
The information in this bulletin is provided "AS IS" without warranty of any
kind.
In no event shall we be liable for any damages whatsoever including direct,
indirect, incidental, consequential, loss of business profits or special
damages.
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [REVS] Security Testing Demystified, SecuriTeam |
|---|---|
| Next by Date: | [REVS] XST Strikes Back, SecuriTeam |
| Previous by Thread: | [REVS] Security Testing Demystified, SecuriTeam |
| Next by Thread: | [REVS] XST Strikes Back, SecuriTeam |
| Indexes: | [Date] [Thread] [Top] [All Lists] |