To anyone using Simple PHP Blog, here is a way to lock down the password a bit more than it is now.
line numbers may vary due to version
line 42
change$passFile = 'config/password.txt';
to$passFile = 'config/pwd.php';
line 89
change$filename = 'config/password.txt';
to$hashed = crypt($mypasswd);
$tmphashed = "<?php $thepass = "".str_replace("$","$",$hashed).""; ?>";
$hashed = $tmphashed;
$filename = 'config/pwd.php';
line 114
change$passFile = 'config/password.txt';
$hashed = sb_read_file( $passFile );
to$passFile = 'config/pwd.php';
require( $passFile );
$hashed = $thepass;
logout of your site, go back to your homepage, and you will have to walk through the setup up to the password creation… another option is to rename password.txt to pwd.php and edit it fromPASSWORDSTRING
to<?php $thepass = "PASSWORDSTRING"; ?>
be sure to replace any $ with $
I’ve been an ASP developer for years, and I’m just migrating over to PHP, so I can only state that this works for me and I take no responsibility if this does not work for you or causes any problems on your site.
SPHPBLOG
Comments (View)