Closed (cannot reproduce)
Project:
elFinder file manager
Version:
7.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
15 Apr 2012 at 15:11 UTC
Updated:
15 Jun 2012 at 03:55 UTC
The badfiles array is missing from the elfinder_init() function, which throws an error when called in the foreach() loop.
function elfinder_init() {
$libpath = elfinder_lib_path();
$badpaths = array();
foreach ($badfiles as $badfile) {
$path = $libpath . '/' . $badfile;
if (file_exists($path)) {
$badpaths[] = $path;
}
}
if (count($badpaths) > 0) {
drupal_set_message(t('elFinder library directory containing features test files :files. Please remove these files to avoid security hole.', array(':files' => implode(', ', $badpaths))), 'warning');
}
}
I pulled the following badfiles array from a previous version of this module, which seems to resolve this issue when dropped in the beginning of this function:
function elfinder_init() {
$libpath = elfinder_lib_path();
$badfiles = array('elfinder.html', 'elfinder.php.html', 'connectors/php/connector.php', 'php/connector.php');
$badpaths = array();
foreach ($badfiles as $badfile) { ... }
...
}
Comments
Comment #1
ph0enix commentedStrange. Just checked latest dev branch - $badfiles is presented in code
Comment #2
ph0enix commented