The installation of “FileProtect” is very simple. Only 5 steps are necessary:Change the ‘Settings’ of the login.php to your need (FileProtect will run without any changes but all settings are also well documented) Replace the fileprotect_logo.png with your desired logo Copy the ‘4 magic lines of code’ from the login.php at the beginning of the file that should be protected (in most cases index.php) upload all files to the desired folder test it
The 4 magic lines of code are: (add this php code to all .php files that should be protected)
include "fileprotect/fileprotect_class.php";
session_start();
$fp = new FileProtect;
$fp->CheckAccess();
Features
- “FileProtect” is simple and flexible
– it integrates perfectly at every time of your project. Existing files or struktures never have to be renamed or changed.
– only 4 lines of code to protect a file
– runs out of the box without any changes - no database required – but ready to work with an sql database
- Username or Password could be defined in the settings or could be read from any sql database
- ready to deal with md5 encrypted password
- individual help text at the login page possible
- Automatic .htaccess creation to redirect from non-existing files and subfolders back to the login screen
- Possibility to protect specific file extensions from direct access
- German and English Translations available. Easy to extend with other languages due to standardized language files.
- resistant against BruteForce attacks
- check out the demo at http://www.bigtoe.de/demo/fileprotect