Hello, I’m scanning through the source and every once in a while I’m coming across files such as interface/login/validateUser.php, library/sqlconf.php, and contrib/util/express.php.
The first is a stub of a former security risk, the second is an indirect include of the $site sqlconf.php, and the third is a script from 4.0.0 that writes to library/sqlconf.php.
I’d like to clear out files such as these as I come across them. What might be the consequence of removing these files?
I haven’t gone through the upgrade process, but couldn’t a checklist style script similar to the setup script be used to check if the file_exists() and provide removal instructions?
Of course all references to the files would have to be updated. For example, files that include library/sqlconf.php would need to require_once($GLOBALS[‘OE_SITE_DIR’] . “/sqlconf.php”);
If there are several such files it could simplify the code. Maybe it would be nice to improve the consistency. For example, sometimes $ignoreAuth = true and sometimes $ignoreAuth = 1. Having a $webserver_root, $web_root, and $rootdir is a little confusing. It might make sense to call $rootdir $interface_dir in the same way there is a $template_dir. Since I’m already scanning through the code it wouldn’t take much effort to find and change little things like these along the way.
Maybe typos, bugs, and old/broken scripts/link are the only things worth reporting.
If you have changes you would like to contribute, then the best thing to do is familiarize yourself with git if you haven’t already. Then submit your commitsfor review after appropriate testing.
The current patch mechanism is to unzip new files on top of an existing installation. While it would be nice to have something more sophisticated which could do “file_exists()” checks and delete old code as you suggest, I personally don’t believe it’s worth devoting resources to that task at this time.
Clearing out interface/login/validateUser.php and contrib/util/express.php on your on installation certainly won’t cause any problems.