Okay, let’s get paranoid…
- Always use SFTP to transfer files.
- Always log into the CP via HTTPS... use .htaccess to enforce this.
- Move your MySQL password out of config.php and replace it with a $variable. Then create a file in a directory ABOVE your public_html directory, and store it there. Then require that file in config.php. Now even if PHP crashes no one can read your MySQL password.
Caveat: you’ll have to CHMOD config.php to 644 or 444 to prevent EE from overwriting it, and then make all changes in the file manually (i.e. not through the CP).
--> in /home/user/includes/mysql_password_include.php
<?php $MySqlVar = 'your_mysql_password'; ?>
--> and in /home/user/public_html/system/config.php
<?php
require("/home/user/includes/mysql_password_include.php");
...
$conf['db_password'] = "$MySqlVar";
?>
- Call /system/ something ridiculous, like a random 20 digit string. Then set up an .htaccess redirect from something easier to remember. You can change the .htaccess redirect url every month, or week, or day depending on your paranoia level, without having to make any changes in your EE settings. Even if someone sees the real URL they won’t be able to remember it.
redirect 301 /tHiS-wEEkz-URL-52678/ <a href="https://mysite.com/system-1yshorIj3Duio7iLZmqo6apA7rgdL86G3/">https://mysite.com/system-1yshorIj3Duio7iLZmqo6apA7rgdL86G3/</a>
- Limit CP login attempts to certain IP addresses, like your office and your home. In /system/index.php do…
<?php
if ($_SERVER['REMOTE_ADDR'] != 'my.off.ice.ip' && $_SERVER['REMOTE_ADDR'] != 'my.hom.e.ip'){
echo "<meta http-equiv='refresh' content='0; url=../'>";
}else{
error_reporting(0);
$pathinfo = pathinfo(__FILE__);
$ext = '.'.$pathinfo['extension'];
require './core/core.system'.$ext;
}
?>
- If you’re not using the Members features, change your member profile triggering word to .member (i.e. member with a period before it). That will block access to all the member templates (credit to the person who posted this trick here on the forums).
- And the thing we should all do more then we do do—change your password frequently!
Okay, back to the bunker…
- i